Improve new Sonos snapshot/restore (#21509)
* Fine-tune new Sonos snapshot/restore * Move into class
This commit is contained in:
1 parent
aa546b5a1f
commit
26a534a67c
2 files changed
+86
-63
No files matched your search
@@ -328,7 +328,7 @@ class TestSonosMediaPlayer(unittest.TestCase):
|
||||
snapshotMock.return_value = True
|
||||
entity.soco.group = mock.MagicMock()
|
||||
entity.soco.group.members = [e.soco for e in entities]
|
||||
sonos.snapshot(entities, True)
|
||||
sonos.SonosEntity.snapshot_multi(entities, True)
|
||||
assert snapshotMock.call_count == 1
|
||||
assert snapshotMock.call_args == mock.call()
|
||||
|
||||
@@ -350,6 +350,6 @@ class TestSonosMediaPlayer(unittest.TestCase):
|
||||
entity._snapshot_group = mock.MagicMock()
|
||||
entity._snapshot_group.members = [e.soco for e in entities]
|
||||
entity._soco_snapshot = Snapshot(entity.soco)
|
||||
sonos.restore(entities, True)
|
||||
sonos.SonosEntity.restore_multi(entities, True)
|
||||
assert restoreMock.call_count == 1
|
||||
assert restoreMock.call_args == mock.call()
|
||||
Reference in new issue
Block a user