diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test_k1c.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_k1c.py b/tests/test_k1c.py index 47c25ec..300a56a 100644 --- a/tests/test_k1c.py +++ b/tests/test_k1c.py @@ -35,7 +35,7 @@ STATUS = { "toolhead": {"position": [10.0, 20.0, 3.2, 100.0]}, "gcode_move": {"speed_factor": 1.0}, } -CAMS = {"result": {"webcams": [{"enabled": True, "snapshot_url": "http://printer.example.org:8080/?action=snapshot"}]}} +CAMS = {"result": {"webcams": [{"enabled": True, "stream_url": "http://printer.example.org:8080/?action=stream"}]}} class Fake: @@ -65,7 +65,7 @@ class K1C(unittest.TestCase): self.assertEqual((st["layer"], st["layers"]), (12, 80)) self.assertEqual(st["extruder"]["target"], 220.0) self.assertEqual(st["position"], [10.0, 20.0, 3.2]) - self.assertTrue(st["snapshot"].endswith("action=snapshot")) + self.assertTrue(st["camera"].endswith("action=stream")) self.assertEqual(st["thumbnail"], URL + "/server/files/gcodes/.thumbs/part-300x300.png") def test_thumbnail_is_relative_to_the_file_and_quoted(self): @@ -107,8 +107,8 @@ class K1C(unittest.TestCase): with self.assertRaises(k1c.ModuleError): m.actions["emergency_stop"]({}) - def test_snapshot_needs_http(self): - self.assertIsNone(k1c._snapshot([{"snapshot_url": "javascript:alert(1)"}])) + def test_camera_needs_http(self): + self.assertIsNone(k1c._camera([{"stream_url": "javascript:alert(1)"}])) if __name__ == "__main__": |
