Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaime van Kessel <nallath@gmail.com>2020-08-14 16:41:40 +0300
committerJaime van Kessel <nallath@gmail.com>2020-08-14 16:41:40 +0300
commit43efac491da3d5c246c75be8509c607b9f93a0d2 (patch)
treee3d6bc92c5aa1e6d8c4be51b80e925d2b66e1009
parentcee7ac2ccc8dfaa298e2ba54954c9fc723f3b229 (diff)
Fix the unit test
Previously we would only look at the state, but that isn't the only thing it should look at. It should override the value of a resolve if it's defined in user changes or QualityChanges.
-rwxr-xr-xtests/Settings/TestGlobalStack.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/Settings/TestGlobalStack.py b/tests/Settings/TestGlobalStack.py
index ab9c034e24..79d326ddae 100755
--- a/tests/Settings/TestGlobalStack.py
+++ b/tests/Settings/TestGlobalStack.py
@@ -410,13 +410,13 @@ def test_getPropertyInstancesBeforeResolve(global_stack):
value = unittest.mock.MagicMock() #Sets just the value.
value.getProperty = unittest.mock.MagicMock(side_effect = getValueProperty)
- value.getMetaDataEntry = unittest.mock.MagicMock(return_value = "quality")
+ value.getMetaDataEntry = unittest.mock.MagicMock(return_value = "quality_changes")
resolve = unittest.mock.MagicMock() #Sets just the resolve.
resolve.getProperty = unittest.mock.MagicMock(side_effect = getResolveProperty)
with unittest.mock.patch("cura.Settings.CuraContainerStack.DefinitionContainer", unittest.mock.MagicMock): #To guard against the type checking.
global_stack.definition = resolve
- global_stack.quality = value
+ global_stack.qualityChanges = value
assert global_stack.getProperty("material_bed_temperature", "value") == 10