From 247a8011b744bcd96fa78d5b78c1085d137f9dce Mon Sep 17 00:00:00 2001 From: gan-of-culture Date: Sun, 17 Dec 2023 03:13:02 +0100 Subject: [PATCH] [tests] added extra info on data mismatch --- test/utils.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/utils.go b/test/utils.go index eedbca9..6c15c5a 100644 --- a/test/utils.go +++ b/test/utils.go @@ -1,6 +1,7 @@ package test import ( + "encoding/json" "testing" "github.com/gan-of-culture/get-sauce/static" @@ -44,6 +45,8 @@ func Check(t *testing.T, args Args, data *static.Data) { Size: defaultData.Size, } if !CheckData(args, temp) { + jsonData, _ := json.MarshalIndent(defaultData, "", " ") + t.Log(jsonData) t.Errorf("Got: %v\nExpected: %v", temp, args) } }