Move skopeoBinary check from *Suite.SetUpTest to SetUpSuite

The results are not going to vary across individual tests, so let’s only
check once.
This commit is contained in:
Miloslav Trmač
2017-05-10 14:02:11 +02:00
parent 5a42657cdb
commit 9985f12cd4
2 changed files with 7 additions and 7 deletions

View File

@@ -34,7 +34,8 @@ type SkopeoSuite struct {
}
func (s *SkopeoSuite) SetUpSuite(c *check.C) {
_, err := exec.LookPath(skopeoBinary)
c.Assert(err, check.IsNil)
}
func (s *SkopeoSuite) TearDownSuite(c *check.C) {
@@ -42,9 +43,6 @@ func (s *SkopeoSuite) TearDownSuite(c *check.C) {
}
func (s *SkopeoSuite) SetUpTest(c *check.C) {
_, err := exec.LookPath(skopeoBinary)
c.Assert(err, check.IsNil)
s.regV1 = setupRegistryV1At(c, privateRegistryURL0, false) // TODO:(runcom)
s.regV2 = setupRegistryV2At(c, privateRegistryURL1, false, false)
s.regV2Shema1 = setupRegistryV2At(c, privateRegistryURL2, false, true)