Skip to content

Commit c0a51b1

Browse files
committed
tests
1 parent e77041d commit c0a51b1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

backend/custom_admin/tests/test_templatetags.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,8 @@ def test_empty_string_if_none():
99

1010

1111
def test_to_json_for_prop():
12+
assert to_json_for_prop([1, 2, 3]) == "[1, 2, 3]"
13+
assert to_json_for_prop(None) == "null"
14+
assert to_json_for_prop(123) == "123"
15+
assert to_json_for_prop("abc") == "\\u0022abc\\u0022"
1216
assert to_json_for_prop({"a": 123}) == "{\\u0022a\\u0022: 123}"

0 commit comments

Comments
 (0)