summaryrefslogtreecommitdiff
path: root/src/test/test_sound_node_client.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/test_sound_node_client.py')
-rwxr-xr-xsrc/test/test_sound_node_client.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/test/test_sound_node_client.py b/src/test/test_sound_node_client.py
new file mode 100755
index 0000000..795165a
--- /dev/null
+++ b/src/test/test_sound_node_client.py
@@ -0,0 +1,19 @@
+#!/usr/bin/env python3
+import sys, os.path
+sys.path.extend([
+ os.path.realpath(os.path.join(os.path.dirname(os.path.join(__file__)), '..', '..')),
+])
+
+from src.home.api.errors import ApiResponseError
+from src.home.sound import SoundNodeClient
+
+
+if __name__ == '__main__':
+ client = SoundNodeClient(('127.0.0.1', 8313))
+ print(client.amixer_get_all())
+
+ try:
+ client.amixer_get('invalidname')
+ except ApiResponseError as exc:
+ print(exc)
+