mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-11-29 22:01:14 -07:00
Test if we actually return the result of the call to getQuality[Changes]Groups
Contributes to issue CURA-6600.
This commit is contained in:
parent
7f192ce36f
commit
5106d3b7c1
1 changed files with 3 additions and 1 deletions
|
|
@ -94,6 +94,7 @@ def test_getCurrentQualityGroups(container_registry, application):
|
||||||
expected_is_enabled = [True, True]
|
expected_is_enabled = [True, True]
|
||||||
|
|
||||||
container_tree.machines["current_global_stack"].getQualityGroups.assert_called_with(expected_variant_names, expected_material_base_files, expected_is_enabled)
|
container_tree.machines["current_global_stack"].getQualityGroups.assert_called_with(expected_variant_names, expected_material_base_files, expected_is_enabled)
|
||||||
|
assert result == container_tree.machines["current_global_stack"].getQualityGroups.return_value
|
||||||
|
|
||||||
def test_getCurrentQualityChangesGroupsNoGlobalStack(container_registry):
|
def test_getCurrentQualityChangesGroupsNoGlobalStack(container_registry):
|
||||||
with patch("UM.Settings.ContainerRegistry.ContainerRegistry.getInstance", MagicMock(return_value = container_registry)):
|
with patch("UM.Settings.ContainerRegistry.ContainerRegistry.getInstance", MagicMock(return_value = container_registry)):
|
||||||
|
|
@ -117,3 +118,4 @@ def test_getCurrentQualityChangesGroups(container_registry, application):
|
||||||
expected_is_enabled = [True, True]
|
expected_is_enabled = [True, True]
|
||||||
|
|
||||||
container_tree.machines["current_global_stack"].getQualityChangesGroups.assert_called_with(expected_variant_names, expected_material_base_files, expected_is_enabled)
|
container_tree.machines["current_global_stack"].getQualityChangesGroups.assert_called_with(expected_variant_names, expected_material_base_files, expected_is_enabled)
|
||||||
|
assert result == container_tree.machines["current_global_stack"].getQualityChangesGroups.return_value
|
||||||
Loading…
Add table
Add a link
Reference in a new issue