mirror of https://github.com/docker/cli.git
Merge pull request #1076 from vdemeester/fix-e2e-system
Fix e2e/system tests
This commit is contained in:
commit
56fc890f35
|
@ -11,6 +11,8 @@ func TestInspectInvalidReference(t *testing.T) {
|
||||||
// This test should work on both Windows and Linux
|
// This test should work on both Windows and Linux
|
||||||
result := icmd.RunCmd(icmd.Command("docker", "inspect", "FooBar"))
|
result := icmd.RunCmd(icmd.Command("docker", "inspect", "FooBar"))
|
||||||
result.Assert(t, icmd.Expected{
|
result.Assert(t, icmd.Expected{
|
||||||
Out: "[]\nError: No such object: FooBar",
|
Out: "[]",
|
||||||
|
Err: "Error: No such object: FooBar",
|
||||||
|
ExitCode: 1,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
package system
|
||||||
|
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
"os"
|
||||||
|
"testing"
|
||||||
|
|
||||||
|
"github.com/docker/cli/internal/test/environment"
|
||||||
|
)
|
||||||
|
|
||||||
|
func TestMain(m *testing.M) {
|
||||||
|
if err := environment.Setup(); err != nil {
|
||||||
|
fmt.Println(err.Error())
|
||||||
|
os.Exit(3)
|
||||||
|
}
|
||||||
|
os.Exit(m.Run())
|
||||||
|
}
|
Loading…
Reference in New Issue