summaryrefslogtreecommitdiffstatshomepage
path: root/tests/pyb/switch.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pyb/switch.py')
-rw-r--r--tests/pyb/switch.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/pyb/switch.py b/tests/pyb/switch.py
new file mode 100644
index 0000000000..4b74e0fd73
--- /dev/null
+++ b/tests/pyb/switch.py
@@ -0,0 +1,6 @@
+from pyb import Switch
+
+sw = pyb.Switch()
+print(sw())
+sw.callback(print)
+sw.callback(None)