Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import pytest
import mopidy_funkwhale.actor
import mopidy_funkwhale.client
import mopidy_funkwhale.library
FUNKWHALE_URL = "https://test.funkwhale"
@pytest.fixture()
def config():
return {
"funkwhale": {"url": FUNKWHALE_URL, "username": "user", "password": "passw0rd"},
"proxy": {},
}
@pytest.fixture
def backend(config):
return mopidy_funkwhale.actor.FunkwhaleBackend(config=config, audio=None)
@pytest.fixture()
def session(backend):
return mopidy_funkwhale.client.get_requests_session(
FUNKWHALE_URL, {}, "test/something"
)
@pytest.fixture()
def client(backend, session):
return backend.client
@pytest.fixture
def library(backend):
return backend.library