When going through the list of tests for many printers to fix them, it's then easier to go through the failed list. They will appear in the same order as in my IDE. Just a bit of an ease of life thing without any real cost.
Done during Turbo Testing & Tooling.
Turns out that the JSON objects extend from dict, so this works.
Also turns out that strings have a __getitem__. Who knew?
Done during Turbo Testing & Tooling.
This should not be done anywhere since the default_value won't have any effect then. We disregard CuraEngine's command line method here but that's infeasible with those profiles anyway.
Done during Turbo Testing & Tooling.
We don't want to use it outside of the mapping. This mapping should be transparent.
We are still using it from our tests though but that's fine. Tests are allowed to touch private fields.
Contributes to issue CURA-6793.
The new lazy loading requests different functions from the registry so we need to mock that out.
Also fix the manual insertion of things into the lazy-loaded mapping.
Contributes to issue CURA-6793.
It's not behaving as expected here. For instance, Ultimaker 3 wasn't specifying has_machine_materials and thus only the base materials would get loaded, but clearly the Ultimaker 3 has materials specialised for it.
Whether or not a printer has materials specialised for it is now determined by whether the specialisations exist in the material files. So we don't need the metadata entry any more. It seemed to have not been in use anyway, except by one printer which specified that has_machine_materials is true. I've now made it behave as if it's always true.
Contributes to issue CURA-6831.
These are used by the code. Otherwise there would be an AttributeError of 'intent' not existing, and the quality type in the quality node wouldn't match because it's a magic mock.
Because global_stack.extruders.values can be returned in any order, the configurations matching with the lists doesn't always give a result.
It happened to work on my computer with the test, but there is no guarantee of that.
This is probably also going wrong in other places. I don't think we should use the .extruders property anywhere really!
Contributes to issue CURA-6600.