atc: structure: integration test covers Validate()
concourse/concourse#5421
Rather than `UnmarshalFlag`, since this test is effectively asserting that
`Validate` gets called -- or more generally that there is some kind of
validation across the full set of concurrent-request-limit-related flags.
@@ -33,12 +33,14 @@ func (s *CommandSuite) TestInvalidConcurrencyLimit() {
"--client-secret",
"client-secret",
"--concurrent-request-limit",
- "InvalidAction=2",
+ "ListAllJobs=2",
+ "--concurrent-request-limit",
+ "ListAllJobs=2",
})
_, err := cmd.Runner([]string{})
- s.Errorf(err, "invalid concurrent request limit 'InvalidAction=2': 'InvalidAction' is not a valid action")
+ s.Errorf(err, "invalid concurrent request limits: multiple limits for 'ListAllJobs'")
}
func TestSuite(t *testing.T) {
