From 0f445dff07226c5b7fe1bca74ea593dde56dc5a0 Mon Sep 17 00:00:00 2001 From: Matthew Hooker Date: Fri, 3 Feb 2017 15:03:19 -0800 Subject: [PATCH] fix tests --- provisioner/ansible-local/provisioner_test.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/provisioner/ansible-local/provisioner_test.go b/provisioner/ansible-local/provisioner_test.go index 45ee1c6e3..656ab944d 100644 --- a/provisioner/ansible-local/provisioner_test.go +++ b/provisioner/ansible-local/provisioner_test.go @@ -1,10 +1,12 @@ package ansiblelocal import ( - "github.com/mitchellh/packer/packer" "io/ioutil" "os" + "strings" "testing" + + "github.com/mitchellh/packer/packer" ) func testConfig() map[string]interface{} { @@ -36,7 +38,7 @@ func TestProvisionerPrepare_Defaults(t *testing.T) { t.Fatalf("err: %s", err) } - if p.config.StagingDir != DefaultStagingDir { + if !strings.HasPrefix(p.config.StagingDir, DefaultStagingDir) { t.Fatalf("unexpected staging dir %s, expected %s", p.config.StagingDir, DefaultStagingDir) }