mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-13 04:29:01 +08:00
Fix test_setQualityByIdExists
It now also uses the return_value construct. Contributes to issue CURA-3497.
This commit is contained in:
parent
d652e4564e
commit
c5cce10786
@ -573,8 +573,9 @@ def test_setPropertyOtherContainers(target_container, writable_global_stack):
|
|||||||
|
|
||||||
## Tests setting qualities by specifying an ID of a quality that exists.
|
## Tests setting qualities by specifying an ID of a quality that exists.
|
||||||
def test_setQualityByIdExists(global_stack, container_registry):
|
def test_setQualityByIdExists(global_stack, container_registry):
|
||||||
container_registry.typeMetaData = "quality"
|
container_registry.return_value = getInstanceContainer(container_type = "quality")
|
||||||
global_stack.setQualityById("some_quality") #The container registry always has a container with the ID.
|
global_stack.setQualityById("InstanceContainer")
|
||||||
|
global_stack.quality.getId() == "InstanceContainer"
|
||||||
|
|
||||||
## Tests setting qualities by specifying an ID of a quality that doesn't exist.
|
## Tests setting qualities by specifying an ID of a quality that doesn't exist.
|
||||||
def test_setQualityByIdDoesntExist(global_stack):
|
def test_setQualityByIdDoesntExist(global_stack):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user