aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorElena ``of Valhalla'' Grandi <valhalla@trueelena.org>2019-05-01 17:59:33 +0200
committerElena ``of Valhalla'' Grandi <valhalla@trueelena.org>2019-05-01 17:59:33 +0200
commitd1bffce0242f721a4bd3a61e88aaff6f6fa49248 (patch)
tree318898c7f8322827442c1fdcfcfbe6b2afcb46f0 /tests
parent030d6818c0f6d2d330414feea6fd28b1b60869e7 (diff)
Start listening for future commands on a socket.
Diffstat (limited to 'tests')
-rw-r--r--tests/data/test_config.yaml1
-rw-r--r--tests/test_ctl.py18
2 files changed, 19 insertions, 0 deletions
diff --git a/tests/data/test_config.yaml b/tests/data/test_config.yaml
index 4a485ff..c85a935 100644
--- a/tests/data/test_config.yaml
+++ b/tests/data/test_config.yaml
@@ -1 +1,2 @@
backend: memory
+ctl_socket: tempfile
diff --git a/tests/test_ctl.py b/tests/test_ctl.py
new file mode 100644
index 0000000..404a430
--- /dev/null
+++ b/tests/test_ctl.py
@@ -0,0 +1,18 @@
+import os
+import tempfile
+
+from tornado.testing import AsyncTestCase
+
+from pyapd import ctl, config
+
+
+class TestCtlServer(AsyncTestCase):
+ def setUp(self):
+ super().setUp()
+ self.tempdir = tempfile.TemporaryDirectory()
+ conf = config.Config('tests/data/test_config.yaml')
+ conf.ctl_socket = os.path.join(self.tempdir.name, 'pyapd.sock')
+ self.ctl_server = ctl.CtlServer(conf)
+
+ def test_nothing(self):
+ pass