From 51205fd4c54499dce894aa1b64b74e343bd51406 Mon Sep 17 00:00:00 2001 From: Ultrabug Date: Sun, 21 Dec 2014 20:06:22 +0100 Subject: add standalone test code --- py3status/modules/whoami.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'py3status') diff --git a/py3status/modules/whoami.py b/py3status/modules/whoami.py index a5e27ed..f2f8571 100644 --- a/py3status/modules/whoami.py +++ b/py3status/modules/whoami.py @@ -28,3 +28,13 @@ class Py3status: 'full_text': username } return response + +if __name__ == "__main__": + """ + Test this module by calling it directly. + """ + from time import sleep + x = Py3status() + while True: + print(x.whoami([], {})) + sleep(1) -- cgit v1.3