Beispiel #1
0
 def test_save(self):
     """
     Save a new setup and retrieve it
     """
     with mock.patch("usb.core.find"):
         b = Backend()
     with open(setup_file.DEFAULT_CONFIG_FILE_NAME) as file:
         default_setup = json.load(file)
     default_setup["tps"]["label"] = "test"
     b.save(default_setup)
     assert b.setup() == default_setup
     b.stop()