From b59c12a70d4722ed96ca0f770d0bc7f28e582a53 Mon Sep 17 00:00:00 2001 From: Sapphire Becker <41972890+sapphire-janrain@users.noreply.github.com> Date: Wed, 10 Mar 2021 17:18:32 -0800 Subject: [PATCH] Remove go-spew dependency (#483) --- benchmark/go.sum | 2 -- go.mod | 2 -- go.sum | 2 -- parser_test.go | 4 +--- toml_testgen_support_test.go | 4 +--- 5 files changed, 2 insertions(+), 12 deletions(-) delete mode 100644 go.sum diff --git a/benchmark/go.sum b/benchmark/go.sum index 6772ccc4..9bcfb247 100644 --- a/benchmark/go.sum +++ b/benchmark/go.sum @@ -1,7 +1,5 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= diff --git a/go.mod b/go.mod index e924cb90..7d29a0a6 100644 --- a/go.mod +++ b/go.mod @@ -1,5 +1,3 @@ module github.com/pelletier/go-toml go 1.12 - -require github.com/davecgh/go-spew v1.1.1 diff --git a/go.sum b/go.sum deleted file mode 100644 index b5e2922e..00000000 --- a/go.sum +++ /dev/null @@ -1,2 +0,0 @@ -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= diff --git a/parser_test.go b/parser_test.go index 60fa375b..a2338b71 100644 --- a/parser_test.go +++ b/parser_test.go @@ -6,8 +6,6 @@ import ( "reflect" "testing" "time" - - "github.com/davecgh/go-spew/spew" ) func assertSubTree(t *testing.T, path []string, tree *Tree, err error, ref map[string]interface{}) { @@ -39,7 +37,7 @@ func assertSubTree(t *testing.T, path []string, tree *Tree, err error, ref map[s } func assertTree(t *testing.T, tree *Tree, err error, ref map[string]interface{}) { - t.Log("Asserting tree:\n", spew.Sdump(tree)) + t.Logf("Asserting tree:\n (%T)(%p)(%+v)", tree, tree, tree) assertSubTree(t, []string{}, tree, err, ref) t.Log("Finished tree assertion.") } diff --git a/toml_testgen_support_test.go b/toml_testgen_support_test.go index eef9b9fa..de876812 100644 --- a/toml_testgen_support_test.go +++ b/toml_testgen_support_test.go @@ -8,8 +8,6 @@ import ( "reflect" "testing" "time" - - "github.com/davecgh/go-spew/spew" ) func testgenInvalid(t *testing.T, input string) { @@ -56,7 +54,7 @@ func testgenValid(t *testing.T, input string, jsonRef string) { } if !reflect.DeepEqual(jsonExpected, jsonTest) { - t.Logf("Diff:\n%s", spew.Sdump(jsonExpected, jsonTest)) + t.Logf("Diff:\n%#+v\n%#+v", jsonExpected, jsonTest) t.Fatal("parsed TOML tree is different than expected structure") } }