Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
JarbasAl committed May 24, 2024
1 parent 258ed0a commit 8fadf4c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ovos_utils/ocp.py
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,7 @@ def __contains__(self, item):
item = dict2entry(item)
for e in self.entries:
if isinstance(item, PluginStream) and isinstance(e, PluginStream):
if e.stream == item.stream:
if e.stream == item.stream and e.extractor_id == item.extractor_id:
return True
elif isinstance(item, MediaEntry) and isinstance(e, MediaEntry):
if e.uri == item.uri:
Expand Down
2 changes: 1 addition & 1 deletion test/unittests/test_events.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def test_event_container(self):
self.assertEqual(len(bus.ee.listeners("once_event")), 1)
new_event = container.events[-1]
self.assertEqual(new_event[0], "once_event")
self.assertNotEquals(new_event[1], handler)
self.assertNotEqual(new_event[1], handler)
self.assertEqual(len(inspect.signature(new_event[1]).parameters), 1)

# Test iterate events
Expand Down
2 changes: 1 addition & 1 deletion test/unittests/test_ocp_media.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def test_from_dict(self):
new_entry = MediaEntry.from_dict(dict_data)
self.assertEqual(from_dict, new_entry)

self.assertIsInstance(MediaEntry.from_dict({}), MediaEntry)
self.assertIsInstance(MediaEntry.from_dict({"uri": "xxx"}), MediaEntry)


class TestPlaylist(unittest.TestCase):
Expand Down

0 comments on commit 8fadf4c

Please sign in to comment.