From 3f1a9766f43f2fb3c62fed61c0fe51195068bf07 Mon Sep 17 00:00:00 2001 From: Matthew Hooker Date: Fri, 24 Aug 2018 16:18:21 -0700 Subject: [PATCH] formatting verb fixes for go 1.11 --- builder/azure/arm/config.go | 2 +- builder/azure/arm/config_test.go | 4 ++-- common/bootcommand/pc_xt_driver_test.go | 2 -- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/builder/azure/arm/config.go b/builder/azure/arm/config.go index c0adf9ae0..5c81c5aa9 100644 --- a/builder/azure/arm/config.go +++ b/builder/azure/arm/config.go @@ -472,7 +472,7 @@ func assertTagProperties(c *Config, errs *packer.MultiError) { errs = packer.MultiErrorAppend(errs, fmt.Errorf("the tag name %q exceeds (%d) the 512 character limit", k, len(k))) } if len(*v) > 256 { - errs = packer.MultiErrorAppend(errs, fmt.Errorf("the tag name %q exceeds (%d) the 256 character limit", v, len(*v))) + errs = packer.MultiErrorAppend(errs, fmt.Errorf("the tag name %q exceeds (%d) the 256 character limit", *v, len(*v))) } } } diff --git a/builder/azure/arm/config_test.go b/builder/azure/arm/config_test.go index 426e99506..343b85334 100644 --- a/builder/azure/arm/config_test.go +++ b/builder/azure/arm/config_test.go @@ -586,12 +586,12 @@ func TestConfigShouldAcceptTags(t *testing.T) { value := c.AzureTags["tag01"] if *value != "value01" { - t.Errorf("expected AzureTags[\"tag01\"] to have value \"value01\", but got %q", value) + t.Errorf("expected AzureTags[\"tag01\"] to have value \"value01\", but got %q", *value) } value = c.AzureTags["tag02"] if *value != "value02" { - t.Errorf("expected AzureTags[\"tag02\"] to have value \"value02\", but got %q", value) + t.Errorf("expected AzureTags[\"tag02\"] to have value \"value02\", but got %q", *value) } } diff --git a/common/bootcommand/pc_xt_driver_test.go b/common/bootcommand/pc_xt_driver_test.go index 5133f7e85..ab6ef4358 100644 --- a/common/bootcommand/pc_xt_driver_test.go +++ b/common/bootcommand/pc_xt_driver_test.go @@ -124,7 +124,6 @@ func Test_flushes(t *testing.T) { } func Test_KeyIntervalNotGiven(t *testing.T) { - var codes []string sendCodes := func(c []string) error { codes = c return nil @@ -134,7 +133,6 @@ func Test_KeyIntervalNotGiven(t *testing.T) { } func Test_KeyIntervalGiven(t *testing.T) { - var codes []string sendCodes := func(c []string) error { codes = c return nil