Skip to content

Commit af21ff9

Browse files
committed
Add errors test.
1 parent 3f6b1a2 commit af21ff9

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

tests/test_errors.nim

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,10 @@
11
import jsony
2+
3+
doAssertRaises(JsonError):
4+
discard "{invalid".fromJson()
5+
6+
doAssertRaises(JsonError):
7+
discard "{a:}".fromJson()
8+
9+
doAssertRaises(JsonError):
10+
discard "1.23.23".fromJson()

tests/test_json_in_json.nim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import jsony, strutils, json
1+
import jsony, json
22

33
block:
44
type Entry = object

0 commit comments

Comments
 (0)