@@ -17,6 +17,7 @@ const appSettingsFixture string = `
1717 "owner": "test",
1818 "app": "example-go",
1919 "routable": true,
20+ "autodeploy": true,
2021 "autorollback": true,
2122 "allowlist": ["1.2.3.4", "0.0.0.0/0"],
2223 "autoscale": {"cmd": {"min": 3, "max": 8, "cpu_percent": 40}},
@@ -32,6 +33,7 @@ const appSettingsUnsetFixture string = `
3233 "owner": "test",
3334 "app": "unset-test",
3435 "routable": true,
36+ "autodeploy": true,
3537 "autorollback": true,
3638 "allowlist": ["1.2.3.4", "0.0.0.0/0"],
3739 "autoscale": {"cmd": {"min": 3, "max": 8, "cpu_percent": 40}},
@@ -41,8 +43,8 @@ const appSettingsUnsetFixture string = `
4143 "uuid": "de1bf5b5-4a72-4f94-a10c-d2a3741cdf75"
4244}
4345`
44- const appSettingsSetExpected string = `{"routable":true,"allowlist":["1.2.3.4","0.0.0.0/0"],"autorollback":true,"autoscale":{"cmd":{"min":3,"max":8,"cpu_percent":40}},"label":{"git_repo":"https://github.com/drycc/controller-sdk-go","team":"drycc"}}`
45- const appSettingsUnsetExpected string = `{"routable":true,"allowlist":["1.2.3.4","0.0.0.0/0"],"autorollback":true,"autoscale":{"cmd":{"min":3,"max":8,"cpu_percent":40}},"label":{"git_repo":"https://github.com/drycc/controller-sdk-go","team":"drycc"}}`
46+ const appSettingsSetExpected string = `{"routable":true,"allowlist":["1.2.3.4","0.0.0.0/0"],"autodeploy":true," autorollback":true,"autoscale":{"cmd":{"min":3,"max":8,"cpu_percent":40}},"label":{"git_repo":"https://github.com/drycc/controller-sdk-go","team":"drycc"}}`
47+ const appSettingsUnsetExpected string = `{"routable":true,"allowlist":["1.2.3.4","0.0.0.0/0"],"autodeploy":true," autorollback":true,"autoscale":{"cmd":{"min":3,"max":8,"cpu_percent":40}},"label":{"git_repo":"https://github.com/drycc/controller-sdk-go","team":"drycc"}}`
4648
4749type fakeHTTPServer struct {}
4850
@@ -117,6 +119,7 @@ func TestAppSettingsSet(t *testing.T) {
117119 Owner : "test" ,
118120 App : "example-go" ,
119121 Routable : api .NewRoutable (),
122+ Autodeploy : api .NewAutodeploy (),
120123 Autorollback : api .NewAutorollback (),
121124 Allowlist : []string {"1.2.3.4" , "0.0.0.0/0" },
122125 Autoscale : map [string ]* api.Autoscale {
@@ -137,6 +140,7 @@ func TestAppSettingsSet(t *testing.T) {
137140
138141 appSettingsVars := api.AppSettings {
139142 Routable : api .NewRoutable (),
143+ Autodeploy : api .NewAutodeploy (),
140144 Autorollback : api .NewAutorollback (),
141145 Allowlist : []string {"1.2.3.4" , "0.0.0.0/0" },
142146 Autoscale : map [string ]* api.Autoscale {
@@ -179,6 +183,7 @@ func TestAppSettingsUnset(t *testing.T) {
179183 Owner : "test" ,
180184 App : "unset-test" ,
181185 Routable : api .NewRoutable (),
186+ Autodeploy : api .NewAutodeploy (),
182187 Autorollback : api .NewAutorollback (),
183188 Allowlist : []string {"1.2.3.4" , "0.0.0.0/0" },
184189 Autoscale : map [string ]* api.Autoscale {
@@ -199,6 +204,7 @@ func TestAppSettingsUnset(t *testing.T) {
199204
200205 appSettingsVars := api.AppSettings {
201206 Routable : api .NewRoutable (),
207+ Autodeploy : api .NewAutodeploy (),
202208 Autorollback : api .NewAutorollback (),
203209 Allowlist : []string {"1.2.3.4" , "0.0.0.0/0" },
204210 Autoscale : map [string ]* api.Autoscale {
@@ -241,6 +247,7 @@ func TestAppSettingsList(t *testing.T) {
241247 Owner : "test" ,
242248 App : "example-go" ,
243249 Routable : api .NewRoutable (),
250+ Autodeploy : api .NewAutodeploy (),
244251 Autorollback : api .NewAutorollback (),
245252 Allowlist : []string {"1.2.3.4" , "0.0.0.0/0" },
246253 Autoscale : map [string ]* api.Autoscale {
0 commit comments