aboutsummaryrefslogtreecommitdiff
path: root/telegabber_test.go
blob: 459f3334008da08974452d8dc98ce3e846628905 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
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")
	}
}