Fix integration-cli suite setup requirements
This PR moves the testRequires check from within setupRegistry and setupNotary to when the Suite itself starts up. This fixes a bug where testRequires() in setupRegistry() would succeed and start registry, but testRequires() in setupNotary() would fail. This immediately exits the goroutine with registry still running. Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com> Upstream-commit: d800a4e1ba7d23864aa541c1919465bcf22dd1a9 Component: engine
This commit is contained in:
@ -1573,7 +1573,6 @@ func daemonTime(c *check.C) time.Time {
|
||||
}
|
||||
|
||||
func setupRegistry(c *check.C, schema1, auth bool) *testRegistryV2 {
|
||||
testRequires(c, RegistryHosting)
|
||||
reg, err := newTestRegistryV2(c, schema1, auth)
|
||||
c.Assert(err, check.IsNil)
|
||||
|
||||
@ -1590,7 +1589,6 @@ func setupRegistry(c *check.C, schema1, auth bool) *testRegistryV2 {
|
||||
}
|
||||
|
||||
func setupNotary(c *check.C) *testNotary {
|
||||
testRequires(c, NotaryHosting)
|
||||
ts, err := newTestNotary(c)
|
||||
c.Assert(err, check.IsNil)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user