There was an error while loading. Please reload this page.
1 parent 217c073 commit 5a573f2Copy full SHA for 5a573f2
src/test/java/com/jsoniter/TestInteger.java
@@ -86,6 +86,14 @@ public void test_streaming() throws IOException {
86
test_large_number();
87
}
88
89
+ public void test_leading_zero() throws IOException {
90
+ try {
91
+ JsonIterator.deserialize("001", int.class);
92
+ fail();
93
+ } catch (JsonException e) {
94
+ }
95
96
+
97
private int parseInt(String input) throws IOException {
98
if (isStreaming) {
99
JsonIterator iter = JsonIterator.parse(new ByteArrayInputStream(input.getBytes()), 2);
0 commit comments