My intention is to use this to handle GStreamer stuff so I can separate out the higher level functions like next(), previous(), and load_track() Signed-off-by: Anna Schumaker <Anna@NoWheyCreamery.com>
16 lines
606 B
Python
16 lines
606 B
Python
# Copyright 2021 (c) Anna Schumaker.
|
|
import unittest
|
|
from gi.repository import GObject
|
|
from gi.repository import Gst
|
|
from . import bass
|
|
|
|
class TestBassPlayer(unittest.TestCase):
|
|
def test_bass_player_init(self):
|
|
base = bass.BassPlayer()
|
|
self.assertIsInstance(base, GObject.GObject)
|
|
self.assertIsInstance(base.video, Gst.Element)
|
|
self.assertIsInstance(base.playbin, Gst.Element)
|
|
self.assertEqual(base.playbin.get_property("video-sink"), base.video)
|
|
self.assertEqual(base.playbin.get_state(Gst.CLOCK_TIME_NONE)[1],
|
|
Gst.State.READY)
|