7641 Commits

Author SHA1 Message Date
Jaime van Kessel
69c3baf87f Fixed unit test
CURA-3497
2017-05-02 11:06:25 +02:00
Jaime van Kessel
c815077278 Fixed the upgraderFileRename test
CURA-3479
2017-05-01 17:28:55 +02:00
Jaime van Kessel
e6e442348b Fixed one of the tests
The test failed due to it not creating the right application CURA-3497
2017-05-01 16:10:05 +02:00
Jack Ha
8a227c0269 Revert permissions 2017-04-25 11:19:37 +02:00
Jack Ha
74059a82a5 Added some smoketests. CURA-3297 2017-04-25 11:18:55 +02:00
Jack Ha
ed23e6f5b2 Removed more commented out code. CURA-3497 2017-04-25 08:56:28 +02:00
Jack Ha
163929196d Removed commented out code. CURA-3497 2017-04-25 08:50:22 +02:00
Jack Ha
c91bc015e4 Removed unused variables. CURA-3497 2017-04-25 08:43:44 +02:00
Jack Ha
765ddefd7f Reverse lookup TypeIndexMap is now also a dict. CURA-3497 2017-04-24 16:09:00 +02:00
Arjen Hiemstra
ab1044de7b Some more documentation 2017-04-19 14:41:32 +02:00
Arjen Hiemstra
7a907aa713 Deprecate addMachineExtruders/createExtruderTrain 2017-04-18 17:42:40 +02:00
Arjen Hiemstra
0467a8688a Make the UM3 work properly 2017-04-18 17:42:20 +02:00
Arjen Hiemstra
0a0353da82 Move code to set default variant/material/quality to CuraContainerStack
This allows us to eventually make sure everything uses the same code.
2017-04-18 17:41:48 +02:00
Arjen Hiemstra
8682eb1486 Document CuraContainerStack 2017-04-18 17:40:12 +02:00
Arjen Hiemstra
f1b5098a0a Document CuraStackBuilder 2017-04-18 17:38:44 +02:00
Arjen Hiemstra
edc5b8b84e Register extruders with ExtruderManager
For backward compatibility
2017-04-18 17:38:09 +02:00
Arjen Hiemstra
de57546020 Document ExtruderStack 2017-04-18 17:37:52 +02:00
Arjen Hiemstra
8e1580d8d9 Document GlobalStack 2017-04-18 17:37:26 +02:00
Arjen Hiemstra
af3f340fc2 Handle the fact that findContainers might end up returning None
Since we now do not necessarily have a container with the specified
type.
2017-04-18 17:37:05 +02:00
Arjen Hiemstra
0fee41d519 Allow CuraStackBuilder to determine the "default" variant/material/quality 2017-04-13 01:39:11 +02:00
Arjen Hiemstra
b87e7c46bf Use the normal empty container for quality changes as well 2017-04-13 01:37:45 +02:00
Arjen Hiemstra
33301c835b Use CuraStackBuilder::createMachine when adding a new machine 2017-04-13 01:37:26 +02:00
Arjen Hiemstra
f154db13b1 Add a createMachine method to CuraStackBuilder that creates a complete machine 2017-04-13 01:37:01 +02:00
Arjen Hiemstra
df8bba6c96 Add "machine" metadata entry when setting the next stack for an extruder 2017-04-13 01:33:22 +02:00
Arjen Hiemstra
0c232c9462 ExtruderStack requires a next stack, so make sure it has that in tests 2017-04-12 12:06:02 +02:00
Arjen Hiemstra
d29ae60d38 Add missing Any import 2017-04-12 12:05:40 +02:00
Ghostkeeper
70055d35c0
Remove superfluous mocking and fixtures
These are now no longer used by the tests.

Contributes to issue CURA-3497.
2017-04-12 10:00:45 +02:00
Ghostkeeper
eaf180c150
Let setProperty tests test only whether setProperty on container is called
This makes these tests more simple to mock and stuff and also removes all dependencies of these tests.

Contributes to issue CURA-3497.
2017-04-12 10:00:45 +02:00
Ghostkeeper
06797abafe
Change expected exception in test_set...ByIdDoesntExist
It should raise an InvalidContainerError rather than a KeyError.

Contributes to issue CURA-3497.
2017-04-12 10:00:45 +02:00
Ghostkeeper
0e82c84790
Let test_setVariantByIdExists use new container registry functionality
It sets the container it expects beforehand and tests for its ID.

Contributes to issue CURA-3497.
2017-04-12 10:00:45 +02:00
Ghostkeeper
4db7c6ae66
Let test_setQualityChangesByIdExists use new container registry functionality
It sets the container it expects beforehand and tests for its ID.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
972e94386c
Let test_setQualityByIdExists use new container registry functionality
It sets the container it expects beforehand and tests for its ID.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
27f053ad7b
Let test_setMaterialByIdExists use new container registry functionality
It sets the container it expects beforehand and tests for its ID.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
361b58f49c
Let container_registry return a pre-set value for what containers it finds
This makes a lot of tests more simple, without requiring elaborate mocks, patches and fixtures.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
479176bc6f
Remove superfluous mocking and fixtures
There, that's better.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
09ab895feb
Only test whether setProperty calls setProperty on proper container
It sets up a mock container and records whether setProperty is called on that container. Whether that actually sets the property correctly is up to the instance container.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
2161cf9f52
Remove superfluous output_value parameter
It's not used any more since we don't test the actual instance container any more.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
7f1930d452
Rewrite test_setPropertyUser
It now only checks if setProperty is being called on the user changes instance, not what the result of that should be.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
52d6c074f5
Align parameters of test_setPropertyUser
For readability.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
2c9e115488
Add test for hasUserValue returning false
When a value is not in user changes or in quality changes, it is no longer a user value so it shouldn't get marked as one.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
bbddc2308e
Don't use MockContainer in hasUserChanges tests
This makes the testing code much simpler.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
e0c8a52eec
Fix test_setVariantByIdExists
It now also uses the return_value construct.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
f08053283e
Fix test_setQualityChangesByIdExists
It now also uses the return_value construct.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
73bd47a0a1
Actually assert that the ID is correct
Oops.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
c5cce10786
Fix test_setQualityByIdExists
It now also uses the return_value construct.

Contributes to issue CURA-3497.
2017-04-12 10:00:44 +02:00
Ghostkeeper
d652e4564e
Fix test_setMaterialByIdExists
It now also uses the return_value construct.

Contributes to issue CURA-3497.
2017-04-12 10:00:43 +02:00
Ghostkeeper
546cacec37
Verify that we set the correct container after set...ByID
Makes sense.

Contributes to issue CURA-3497.
2017-04-12 10:00:43 +02:00
Ghostkeeper
6ba79881df
Use new container registry functionality for test_setDefinitionByIdExists
We can just set the return value of the registry to whatever we like and we'll verify that we got that from the registry and it was put on the stack.

Contributes to issue CURA-3497.
2017-04-12 10:00:43 +02:00
Ghostkeeper
4f83ae3fa7
Remove unused import
It was removed when we removed some of the mocking code earlier.

Contributes to issue CURA-3497.
2017-04-12 10:00:43 +02:00
Ghostkeeper
c3ad7d114a
Set return value of registry.findContainers in the test
This way we need to mock way less. It's the min-cut.

Contributes to issue CURA-3497.
2017-04-12 10:00:43 +02:00