mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-21 21:58:01 -06:00
Actually fix tests
Contributes to CL-1266
This commit is contained in:
parent
4581c1f138
commit
58f1c05564
3 changed files with 5 additions and 4 deletions
|
@ -7,6 +7,7 @@ from UM.OutputDevice.OutputDeviceManager import OutputDeviceManager
|
|||
from cura.UltimakerCloudAuthentication import CuraCloudAPIRoot
|
||||
from ...src.Cloud import CloudApiClient
|
||||
from ...src.Cloud import CloudOutputDeviceManager
|
||||
from ...src.Cloud.Models.CloudClusterResponse import CloudClusterResponse
|
||||
from .Fixtures import parseFixture, readFixture
|
||||
from .NetworkManagerMock import NetworkManagerMock, FakeSignal
|
||||
|
||||
|
@ -55,7 +56,9 @@ class TestCloudOutputDeviceManager(TestCase):
|
|||
devices = self.device_manager.getOutputDevices()
|
||||
# TODO: Check active device
|
||||
|
||||
response_clusters = self.clusters_response.get("data", [])
|
||||
response_clusters = []
|
||||
for cluster in self.clusters_response.get("data", []):
|
||||
response_clusters.append(CloudClusterResponse(**cluster).toDict())
|
||||
manager_clusters = sorted([device.clusterData.toDict() for device in self.manager._remote_clusters.values()],
|
||||
key=lambda cluster: cluster['cluster_id'], reverse=True)
|
||||
self.assertEqual(response_clusters, manager_clusters)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue