test(playout): class creation
This commit is contained in:
parent
ce89678292
commit
dde1af70b2
6 changed files with 65 additions and 0 deletions
8
playout/tests/message_handler_test.py
Normal file
8
playout/tests/message_handler_test.py
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
from queue import Queue
|
||||||
|
|
||||||
|
from libretime_playout.config import Config
|
||||||
|
from libretime_playout.message_handler import MessageListener
|
||||||
|
|
||||||
|
|
||||||
|
def test_message_listener(config: Config):
|
||||||
|
MessageListener(config, Queue())
|
18
playout/tests/player/fetch_test.py
Normal file
18
playout/tests/player/fetch_test.py
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
from queue import Queue
|
||||||
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
|
from libretime_playout.config import Config
|
||||||
|
from libretime_playout.player.fetch import PypoFetch
|
||||||
|
|
||||||
|
|
||||||
|
def test_fetch_thread(config: Config):
|
||||||
|
PypoFetch(
|
||||||
|
Queue(),
|
||||||
|
Queue(),
|
||||||
|
Queue(),
|
||||||
|
MagicMock(),
|
||||||
|
MagicMock(),
|
||||||
|
config,
|
||||||
|
MagicMock(),
|
||||||
|
MagicMock(),
|
||||||
|
)
|
11
playout/tests/player/file_test.py
Normal file
11
playout/tests/player/file_test.py
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
from queue import Queue
|
||||||
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
|
from libretime_playout.player.file import PypoFile
|
||||||
|
|
||||||
|
|
||||||
|
def test_file_thread():
|
||||||
|
PypoFile(
|
||||||
|
Queue(),
|
||||||
|
MagicMock(),
|
||||||
|
)
|
7
playout/tests/player/liquidsoap_test.py
Normal file
7
playout/tests/player/liquidsoap_test.py
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
|
from libretime_playout.player.liquidsoap import PypoLiquidsoap
|
||||||
|
|
||||||
|
|
||||||
|
def test_liquidsoap():
|
||||||
|
PypoLiquidsoap(MagicMock())
|
13
playout/tests/player/push_test.py
Normal file
13
playout/tests/player/push_test.py
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
from queue import Queue
|
||||||
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
|
from libretime_playout.config import Config
|
||||||
|
from libretime_playout.player.push import PypoPush
|
||||||
|
|
||||||
|
|
||||||
|
def test_push_thread(config: Config):
|
||||||
|
PypoPush(
|
||||||
|
Queue(),
|
||||||
|
MagicMock(),
|
||||||
|
config,
|
||||||
|
)
|
8
playout/tests/player/queue_test.py
Normal file
8
playout/tests/player/queue_test.py
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
from queue import Queue
|
||||||
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
|
from libretime_playout.player.queue import PypoLiqQueue
|
||||||
|
|
||||||
|
|
||||||
|
def test_queue_thread():
|
||||||
|
PypoLiqQueue(Queue(), MagicMock())
|
Loading…
Add table
Add a link
Reference in a new issue