mirror of
https://git.sr.ht/~phw/scotty
synced 2025-04-30 21:57:06 +02:00
Moved specifc backends into separate packages
This commit is contained in:
parent
dfaf21b234
commit
48c8843f91
17 changed files with 127 additions and 98 deletions
|
@ -34,7 +34,7 @@ import (
|
|||
func TestNewClient(t *testing.T) {
|
||||
serverUrl := "https://funkwhale.example.com"
|
||||
token := "foobar123"
|
||||
client := funkwhale.New(serverUrl, token)
|
||||
client := funkwhale.NewClient(serverUrl, token)
|
||||
assert.Equal(t, serverUrl, client.HttpClient.BaseURL)
|
||||
assert.Equal(t, token, client.HttpClient.Token)
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ func TestGetHistoryListenings(t *testing.T) {
|
|||
|
||||
token := "thetoken"
|
||||
serverUrl := "https://funkwhale.example.com"
|
||||
client := funkwhale.New(serverUrl, token)
|
||||
client := funkwhale.NewClient(serverUrl, token)
|
||||
setupHttpMock(t, client.HttpClient.GetClient(),
|
||||
"https://funkwhale.example.com/api/v1/history/listenings",
|
||||
"testdata/listenings.json")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue