From d7795d7b256beacd7216b4c3edebe6948f54cae1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Dachary?= Date: Sat, 1 Jul 2023 01:20:44 +0200 Subject: [PATCH] [TESTS] MockVariable temporarily replaces a global value defer test.MockVariable(&variable, 1234)() (cherry picked from commit 9c78752444c2411f20e72b96b7b4fdf5359099d5) --- modules/test/utils.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/modules/test/utils.go b/modules/test/utils.go index 2917741c45..363cfa32d1 100644 --- a/modules/test/utils.go +++ b/modules/test/utils.go @@ -33,3 +33,11 @@ func RedirectURL(resp http.ResponseWriter) string { func IsNormalPageCompleted(s string) bool { return strings.Contains(s, `