From 1ff002f97995ee1bd318dfd88cc422c793b1fede Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Mierzwa?= Date: Wed, 31 Jan 2018 21:26:40 -0800 Subject: [PATCH] Update tests to use new envs instead of legacy --- views_test.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/views_test.go b/views_test.go index de832cb77..4b8990536 100644 --- a/views_test.go +++ b/views_test.go @@ -59,8 +59,8 @@ func TestIndex(t *testing.T) { } func TestIndexPrefix(t *testing.T) { - os.Setenv("WEB_PREFIX", "/prefix") - defer os.Unsetenv("WEB_PREFIX") + os.Setenv("LISTEN_PREFIX", "/prefix") + defer os.Unsetenv("LISTEN_PREFIX") mockConfig() r := ginTestEngine() req, _ := http.NewRequest("GET", "/prefix/", nil) @@ -83,8 +83,8 @@ func TestHelp(t *testing.T) { } func TestHelpPrefix(t *testing.T) { - os.Setenv("WEB_PREFIX", "/prefix") - defer os.Unsetenv("WEB_PREFIX") + os.Setenv("LISTEN_PREFIX", "/prefix") + defer os.Unsetenv("LISTEN_PREFIX") mockConfig() r := ginTestEngine() req, _ := http.NewRequest("GET", "/prefix/help", nil) @@ -447,8 +447,8 @@ var staticFilePrefixTests = []staticFileTestCase{ } func TestStaticFilesPrefix(t *testing.T) { - os.Setenv("WEB_PREFIX", "/sub") - defer os.Unsetenv("WEB_PREFIX") + os.Setenv("LISTEN_PREFIX", "/sub") + defer os.Unsetenv("LISTEN_PREFIX") mockConfig() r := ginTestEngine() for _, staticFileTest := range staticFilePrefixTests {