forked from stleary/JSON-java
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(stleary#887): regressions, unit tests
- JSONArray now evaluates EOF accordingly for empty Array inputs. - JSONTokener fixed indentation - externalized two JSONMLTest cases
- Loading branch information
Showing
8 changed files
with
218 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
91 changes: 91 additions & 0 deletions
91
src/test/resources/JSONArrayExpectedTestCaseForToJsonArrayTest.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
[ | ||
"addresses", | ||
{ | ||
"xsi:noNamespaceSchemaLocation": "test.xsd", | ||
"xmlns:xsi": "http://www.w3.org/2001/XMLSchema-instance" | ||
}, | ||
[ | ||
"address", | ||
{ | ||
"addrType": "my address" | ||
}, | ||
[ | ||
"name", | ||
{ | ||
"nameType": "my name" | ||
}, | ||
"Joe Tester" | ||
], | ||
[ | ||
"street", | ||
"Baker street 5" | ||
], | ||
[ | ||
"NothingHere", | ||
{ | ||
"except": "an attribute" | ||
} | ||
], | ||
[ | ||
"TrueValue", | ||
true | ||
], | ||
[ | ||
"FalseValue", | ||
false | ||
], | ||
[ | ||
"NullValue", | ||
null | ||
], | ||
[ | ||
"PositiveValue", | ||
42 | ||
], | ||
[ | ||
"NegativeValue", | ||
-23 | ||
], | ||
[ | ||
"DoubleValue", | ||
-23.45 | ||
], | ||
[ | ||
"Nan", | ||
"-23x.45" | ||
], | ||
[ | ||
"ArrayOfNum", | ||
[ | ||
"value", | ||
1 | ||
], | ||
[ | ||
"value", | ||
2 | ||
], | ||
[ | ||
"value", | ||
[ | ||
"subValue", | ||
{ | ||
"svAttr": "svValue" | ||
}, | ||
"abc" | ||
] | ||
], | ||
[ | ||
"value", | ||
3 | ||
], | ||
[ | ||
"value", | ||
4.1 | ||
], | ||
[ | ||
"value", | ||
5.2 | ||
] | ||
] | ||
] | ||
] |
Oops, something went wrong.