From e54087ece1dc27cae3bfd527593339c6faa9b5f0 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Wed, 28 Jun 2017 20:50:47 +0100 Subject: [PATCH] Fix config tests to save configData which fixes subsequent tests --- fs/config_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fs/config_test.go b/fs/config_test.go index 22d70f59a..4008fa8ad 100644 --- a/fs/config_test.go +++ b/fs/config_test.go @@ -56,15 +56,18 @@ func TestCRUD(t *testing.T) { oldOsStdout := os.Stdout oldConfigFile := configFile oldConfig := Config + oldConfigData := configData oldReadLine := ReadLine os.Stdout = nil configFile = &path Config = &ConfigInfo{} + configData = nil defer func() { os.Stdout = oldOsStdout configFile = oldConfigFile ReadLine = oldReadLine Config = oldConfig + configData = oldConfigData }() LoadConfig()