mirror of
https://github.com/lyx0/nourybot.git
synced 2024-11-13 19:49:55 +01:00
add whois test
This commit is contained in:
parent
df16e5c3b1
commit
d64272306d
1 changed files with 18 additions and 0 deletions
18
pkg/api/ivr/whois_test.go
Normal file
18
pkg/api/ivr/whois_test.go
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
package ivr
|
||||||
|
|
||||||
|
import "testing"
|
||||||
|
|
||||||
|
func TestWhois(t *testing.T) {
|
||||||
|
t.Run("returns a link to a users profile picture", func(t *testing.T) {
|
||||||
|
request := Whois("nouryqt")
|
||||||
|
response := "User: Nouryqt, ID: 31437432, Created on: 2012-06-18, Color: #00F2FB, Affiliate: false, Partner: false, Staff: false, Admin: false, Bot: false, Bio: me :)"
|
||||||
|
|
||||||
|
got := request
|
||||||
|
want := response
|
||||||
|
|
||||||
|
if got != want {
|
||||||
|
t.Errorf("got %q, want %q", got, want)
|
||||||
|
}
|
||||||
|
|
||||||
|
})
|
||||||
|
}
|
Loading…
Reference in a new issue