You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/setting/setting.go
+8-2Lines changed: 8 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -28,8 +28,10 @@ var (
28
28
CfgProviderConfigProvider
29
29
IsWindowsbool
30
30
31
-
// IsInTesting indicates whether the testing is running. A lot of unreliable code causes a lot of nonsense error logs during testing
32
-
// TODO: this is only a temporary solution, we should make the test code more reliable
31
+
// IsInTesting indicates whether the testing is running (unit test or integration test). It can be used for:
32
+
// * Skip nonsense error logs during testing caused by unreliable code (TODO: this is only a temporary solution, we should make the test code more reliable)
33
+
// * Panic in dev or testing mode to make the problem more obvious and easier to debug
34
+
// * Mock some functions or options to make testing easier (eg: session store, time, URL detection, etc.)
0 commit comments