Revert changes for CURA-5479

It was decided that functionality present in existing plugins is
sufficient. No need to replicate it in our own codebase and
take on the burden of maintenance

CURA-5479
This commit is contained in:
Nino van Hooff 2020-07-07 16:11:03 +02:00
parent 141ad8ff1d
commit 816aaafc19
6 changed files with 24 additions and 72 deletions

View file

@ -8,13 +8,6 @@ from unittest.mock import MagicMock, patch
from UM.MimeTypeDatabase import MimeTypeDatabase, MimeType
def preferencesGetValue(key: str):
if key == "cura/job_name_template":
return "{machine_name_short}_{project_name}"
return '{"omgzomg": {"spool_weight": 10, "spool_cost": 9}}'
def getPrintInformation(printer_name) -> PrintInformation:
mock_application = MagicMock(name = "mock_application")
@ -26,7 +19,7 @@ def getPrintInformation(printer_name) -> PrintInformation:
mocked_extruder_stack.material = mocked_material
mock_application.getInstance = MagicMock(return_value = mock_application)
mocked_preferences.getValue = MagicMock(side_effect = preferencesGetValue)
mocked_preferences.getValue = MagicMock(return_value = '{"omgzomg": {"spool_weight": 10, "spool_cost": 9}}')
global_container_stack = MagicMock()
global_container_stack.definition.getName = MagicMock(return_value = printer_name)