aboutsummaryrefslogtreecommitdiff
path: root/tests/extmod/ujson_loads.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/extmod/ujson_loads.py')
-rw-r--r--tests/extmod/ujson_loads.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/extmod/ujson_loads.py b/tests/extmod/ujson_loads.py
index 05bd62a9b..75e61dacd 100644
--- a/tests/extmod/ujson_loads.py
+++ b/tests/extmod/ujson_loads.py
@@ -33,3 +33,9 @@ my_print(json.loads('{"a":[], "b":[1], "c":{"3":4}}'))
# whitespace handling
my_print(json.loads('{\n\t"a":[]\r\n, "b":[1], "c":{"3":4} \n\r\t\r\r\r\n}'))
+
+# loading nothing should raise exception
+try:
+ json.loads('')
+except ValueError:
+ print('ValueError')