func TestBuildImageError(t *testing.T) { app := App{Build: "test/noCaptainYML/Dockerfile.error", Image: "captain_test"} res := buildImage(app, "latest") assert.NotNil(t, res, "Docker build should return an error") }
func TestTagNonexistingImage(t *testing.T) { app := App{Image: "golang"} res := tagImage(app, "nonexist", "testing") assert.NotNil(t, res, "Docker tag should return an error") println() }
func TestNewConfigInferringValues(t *testing.T) { options.config = "test/noCaptainYML/captain.yml" c := NewConfig(options, false) assert.NotNil(t, c, "Should return infered configuration") }
func TestNewConfig(t *testing.T) { options.config = "test/Simple/captain.yml" c := NewConfig(options, false) assert.NotNil(t, c, "Should return captain.yml configuration") }
func TestReadConfig(t *testing.T) { options.config = "test/Simple/captain.yml" c := readConfig(configFile(options)) assert.NotNil(t, c, "Should return configuration") }
func TestNewConfig(t *testing.T) { c := NewConfig("", "test/Simple/captain.yml", false) assert.NotNil(t, c, "Should return captain.yml configuration") }