parent
6bd8379114
commit
dcb802358b
@ -0,0 +1,19 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestTdlibLogInfo(t *testing.T) {
|
||||
tdlibConstant := stringToTdlibLogConstant(":info")
|
||||
if tdlibConstant != 3 {
|
||||
t.Errorf("Wrong TDlib constant for info")
|
||||
}
|
||||
}
|
||||
|
||||
func TestTdlibLogInvalid(t *testing.T) {
|
||||
tdlibConstant := stringToTdlibLogConstant("ziz")
|
||||
if tdlibConstant != 0 {
|
||||
t.Errorf("Unknown strings should return fatal loglevel")
|
||||
}
|
||||
}
|
@ -1,19 +0,0 @@
|
||||
package telegram
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestLogInfo(t *testing.T) {
|
||||
tdlibConstant := stringToLogConstant(":info")
|
||||
if tdlibConstant != 3 {
|
||||
t.Errorf("Wrong TDlib constant for info")
|
||||
}
|
||||
}
|
||||
|
||||
func TestLogInvalid(t *testing.T) {
|
||||
tdlibConstant := stringToLogConstant("ziz")
|
||||
if tdlibConstant != 0 {
|
||||
t.Errorf("Unknown strings should return fatal loglevel")
|
||||
}
|
||||
}
|
Loading…
Reference in new issue