Skip to content

Commit

Permalink
Fix broken test
Browse files Browse the repository at this point in the history
  • Loading branch information
bonzofenix committed Jun 25, 2024
1 parent fd3365b commit 2d4f61f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 19 deletions.
14 changes: 0 additions & 14 deletions src/autoscaler/scalingengine/config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,20 +138,6 @@ server:
})
})

Context("when it gives a non integer health port", func() {
BeforeEach(func() {
configBytes = []byte(`
health:
port: port
`)
})

It("should error", func() {
Expect(err).To(BeAssignableToTypeOf(&yaml.TypeError{}))
Expect(err).To(MatchError(MatchRegexp("cannot unmarshal .* into int")))
})
})

Context("when it gives a non integer of defaultCoolDownSecs", func() {
BeforeEach(func() {
configBytes = []byte(`defaultCoolDownSecs: NOT-INTEGER-VALUE`)
Expand Down
2 changes: 0 additions & 2 deletions src/autoscaler/scalingengine/config/testdata/invalid.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,5 @@
secret: autoscaler_client_secret
server:
port: 8989
health:
port: 9999
defaultCoolDownSecs: 300
lockSize: 32
4 changes: 1 addition & 3 deletions src/autoscaler/scalingengine/config/testdata/valid.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ server:
key_file: /var/vcap/jobs/autoscaler/config/certs/server.key
cert_file: /var/vcap/jobs/autoscaler/config/certs/server.crt
ca_file: /var/vcap/jobs/autoscaler/config/certs/ca.crt
health:
port: 9999

logging:
level: DeBug
Expand All @@ -32,4 +30,4 @@ db:
connection_max_lifetime: 60s
defaultCoolDownSecs: 300
lockSize: 32
http_client_timeout: 10s
http_client_timeout: 10s

0 comments on commit 2d4f61f

Please sign in to comment.