(t *testing.T)
| 158 | } |
| 159 | |
| 160 | func 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 | |
| 185 | func TestFatalLog(t *testing.T) { |
| 186 | SetStringLevel("willusenextparam", ErrorLevel) |
nothing calls this directly
no test coverage detected