import unittest from pathlib import Path from sliceitoff.sfx import sfx class TestSfx(unittest.TestCase): def test_sfx_is_created_on_import(self): self.assertEqual("", str(type(sfx))) def test_sfx_is_always_same(self): from sliceitoff.sfx import sfx as sfx2 self.assertEqual(sfx, sfx2) def test_init_works(self): sfx.init( Path(__file__).parent.parent.resolve() .joinpath('src').joinpath('sliceitoff').joinpath('assets')) def test_play(self): sfx.play("laser")