Unified code for backend clients and tests

This commit is contained in:
Philipp Wolfer 2023-11-12 16:28:23 +01:00
parent 9316838d59
commit aa01ae1342
No known key found for this signature in database
GPG key ID: 8FDF744D4919943B
11 changed files with 220 additions and 42 deletions

47
backends/maloja/testdata/scrobbles.json vendored Normal file
View file

@ -0,0 +1,47 @@
{
"status": "ok",
"list": [
{
"time": 1699574369,
"track": {
"artists": [
"Hazeshuttle"
],
"title": "Way to Eden",
"album": {
"artists": [
"Hazeshuttle"
],
"albumtitle": "Hazeshuttle"
},
"length": 567
},
"duration": 558,
"origin": "client:Funkwhale"
},
{
"time": 1699573362,
"track": {
"artists": [
"Hazeshuttle"
],
"title": "Homosativa",
"album": {
"artists": [
"Hazeshuttle"
],
"albumtitle": "Hazeshuttle"
},
"length": 1007
},
"duration": null,
"origin": "client:Funkwhale"
}
],
"pagination": {
"page": 0,
"perpage": 2,
"next_page": "/apis/mlj_1/scrobbles?page=1&perpage=2",
"prev_page": null
}
}