MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / TestSimpleLog

Function TestSimpleLog

utils/log/logwrapper_test.go:160–183  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

158}
159
160func TestSimpleLog(t *testing.T) {
161 SetStringLevel("error", ErrorLevel)
162 if GetLevel() != ErrorLevel {
163 t.Fail()
164 }
165 Debug("Debug")
166 Debugln("Debugln")
167 Debugf("Debugf %d", 1)
168 logger := StandardLogger()
169 logger.Printf("StandardLogger Printf %d", 1)
170
171 SimpleLog = "Y"
172 SetLevel(DebugLevel)
173 Debug("Debug")
174 Debugln("Debugln")
175 Debugf("Debugf %d", 1)
176
177 SimpleLog = "N"
178 SetOutput(&NilWriter{})
179 SetFormatter(&NilFormatter{})
180 Debug("Debug")
181 Debugln("Debugln")
182 Debugf("Debugf %d", 1)
183}
184
185func TestFatalLog(t *testing.T) {
186 SetStringLevel("willusenextparam", ErrorLevel)

Callers

nothing calls this directly

Calls 10

SetStringLevelFunction · 0.85
GetLevelFunction · 0.85
DebugFunction · 0.85
DebuglnFunction · 0.85
DebugfFunction · 0.85
StandardLoggerFunction · 0.85
SetLevelFunction · 0.85
SetOutputFunction · 0.85
SetFormatterFunction · 0.85
PrintfMethod · 0.45

Tested by

no test coverage detected