MCPcopy Create free account
hub / github.com/github/gh-aw / TestLoadRepoConfig_MaintenanceEmptyObject

Function TestLoadRepoConfig_MaintenanceEmptyObject

pkg/workflow/repo_config_test.go:87–96  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

85}
86
87func TestLoadRepoConfig_MaintenanceEmptyObject(t *testing.T) {
88 dir := t.TempDir()
89 writeAWJSON(t, dir, `{"maintenance": {}}`)
90
91 cfg, err := LoadRepoConfig(dir)
92 require.NoError(t, err, "aw.json with empty maintenance object should load without error")
93 assert.False(t, cfg.MaintenanceDisabled, "maintenance should not be disabled")
94 require.NotNil(t, cfg.Maintenance, "maintenance config should be set")
95 assert.Empty(t, cfg.Maintenance.RunsOn, "runs_on should be empty when not specified")
96}
97
98func TestLoadRepoConfig_ActionFailureIssueExpires(t *testing.T) {
99 dir := t.TempDir()

Callers

nothing calls this directly

Calls 2

writeAWJSONFunction · 0.85
LoadRepoConfigFunction · 0.85

Tested by

no test coverage detected