From a25f6c37d55a64bc0d5abf3cb7e197178e8e4b40 Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Fri, 14 Apr 2017 12:38:30 -0300 Subject: [PATCH] added more build pipe tests --- pipeline/build/build_test.go | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/pipeline/build/build_test.go b/pipeline/build/build_test.go index 1f1af10eb..721c6f14a 100644 --- a/pipeline/build/build_test.go +++ b/pipeline/build/build_test.go @@ -73,6 +73,26 @@ func TestRunFullPipe(t *testing.T) { assert.True(exists(post), post) } +func TestRunPipeWithInvalidOS(t *testing.T) { + assert := assert.New(t) + var config = config.Project{ + Build: config.Build{ + Flags: "-v", + Goos: []string{ + "windows", + }, + Goarch: []string{ + "arm", + }, + }, + } + var ctx = &context.Context{ + Config: config, + Archives: map[string]string{}, + } + assert.NoError(Pipe{}.Run(ctx)) +} + func exists(file string) bool { _, err := os.Stat(file) return !os.IsNotExist(err)