sk02241994
ffd48afa42
Review comments
2023-12-23 10:53:54 +05:30
sk02241994
abea194120
Adding JSONParserConfiguration for configuring the depth of nested maps
2023-12-22 15:47:55 +05:30
sk02241994
dcac3bc18e
Adding test case for nested json with depth of 999, 1000, 1001
2023-12-22 15:47:54 +05:30
sk02241994
6d811607dd
Resolving issue #743
...
- Recursive depth issue found in JSONObject
- Recursive depth issue found in JSONArray
2023-12-22 15:47:54 +05:30
John J. Aylward
a3742acf74
Fixes #821
...
add ignore annotation to tests that may fail due to differences in machine resources and can't be controlled via the tests
2023-11-06 17:54:09 -05:00
Sean Leary
beb2fb5706
Merge pull request #772 from eamonnmcmanus/complexkey
...
Disallow nested objects and arrays as keys in objects.
2023-10-01 11:04:40 -05:00
Sean Leary
ef68cdf810
Merge pull request #773 from eedijs/master
...
Add optJSONArray method to JSONObject with a default value
2023-09-30 11:47:01 -05:00
Éamonn McManus
eaa5611ba3
Merge branch 'stleary:master' into complexkey
2023-09-28 11:33:08 -07:00
Éamonn McManus
dbb113176b
Add more test cases for unquoted text in objects and arrays.
2023-09-28 11:05:50 -07:00
Edijs
284a316838
Add optJSONArray and optJSONObject methods to JSONArray with a default value
2023-09-27 19:30:45 +03:00
Éamonn McManus
3e688afc66
Small test fixes.
...
One test method was missing `@Test` so it was never run.
One test method used another test class as the base for finding a test
resource. While this works in practice with Maven, it is not strictly
right.
2023-09-19 07:38:13 -07:00
Valentyn Kolesnikov
74cd73f97c
Addressed compile warnings
2023-09-08 07:34:00 +03:00
dburbrid
4951ec48c8
Renamed object methods from ...Obj to ...Object.
...
Added object method for optDoubleObject (returns Double vice double).
Added similar methods in JSONArray.
Added test methods.
2023-06-29 09:39:34 +01:00
Cleydyr de Albuquerque
eb56704e68
fix: set default maximum nesting depth as 512
2023-02-02 18:15:03 +01:00
stleary
89f6e7f6a6
Merge branch 'master' into update-copyright
2022-08-26 20:59:00 -05:00
Sean Leary
346fb26f2d
Merge pull request #683 from spaffrath/Issue_682_JSONString_similarity
...
Issue 682 JSONString similarity
2022-08-26 20:57:22 -05:00
stleary
6daabb43ab
update-copyright - Replace copyright and license restrictions with Public Domain
2022-08-23 20:00:25 -05:00
stleary
e0534b3ec7
initial attempt to test for inconsistent map types in JSONObject
2022-08-20 16:14:34 -05:00
Scott Paffrath
89f16ad0af
Issue 682 JSONString similarity
2022-08-05 11:00:33 -07:00
John J. Aylward
beae279b21
Updates tests to have updated message expectations
2022-03-21 13:06:19 -04:00
John J. Aylward
7a124d857d
Add test cases for invalid input
2022-01-26 12:19:53 -05:00
stleary
c6089e53f5
Fixes Issue #611 JsonArray.similar() returns after number entry check
2021-07-18 19:53:23 -05:00
Ian Lovejoy
75894086e5
Fixed incorrect cast getting float from array
...
Added test for getting float from array
2021-04-27 19:03:35 -07:00
Stranck
efad1d73a7
Added UnitTests
...
(I hope they works :c)
2020-12-04 04:09:19 +01:00
John J. Aylward
f37c2d67c5
Update for JSONArray.putAll methods
...
* Adds a copy constructor for JSONArray
* Updates the JSONArray.addAll(Object) method to be more lenient
* Adds support for JSONArray.putAll of generic Iterables
* Adds support for JSONArray.putAll of another JSONArray
2020-07-30 10:10:06 -04:00
Sean Leary
870fa03a19
Merge pull request #529 from ethauvin/master
...
Added putAll(Collection) and putAll(Array) methods.
2020-07-25 12:45:44 -05:00
Sean Leary
78528102d0
Merge pull request #543 from johnjaylward/RefactorXmlConfiguration
...
Refactor XMLConfiguration to use Builder Pattern
2020-07-24 02:49:28 -05:00
Erik C. Thauvin
0d13e56064
Added tests for consecutive calls to putAll.
2020-07-21 23:09:28 -07:00
John J. Aylward
5a31f9ef5f
Refs #541
...
Updates XML configuration to use a builder pattern instead of
constructors with many parameters
2020-07-21 11:08:40 -04:00
stleary
c63e78bbc7
initial commit
2020-07-18 17:14:39 -05:00
vivek
d088cf014e
Development for stleary#516 completed with rebased repository
...
- Introduced JSONObject(int) constructor.
- int > Initial capacity of the underlying data structure
- Test for new introduced JSONArray(int) constructor.
1. Checked with input parameter: 0
2. Checked with input parameter: positive number
3. Checked with positive number input parameter and compared length
4. If input parameter is negative number JSONException is thrown:
JSONArray initial capacity cannot be negative.
2020-06-03 11:46:48 +02:00
John J. Aylward
56d33b8061
changes number parsing to use BigDecimal as the backing type
...
* updated tests to support BigDecimal as the backing type for numbers
* updated some test resource handling to java7 try-with-resources format
* cleaned up some other minor compiler warnings
2020-05-26 10:10:36 -04:00
stleary
2b0a8838ef
gradle support
2020-05-22 11:17:44 -05:00
John J. Aylward
fb01575394
Test cases updates for standardized exception messages
2019-09-17 10:47:16 -04:00
John J. Aylward
3e6c0a51bd
update expected exception text in tests to match unified number getters
2018-10-04 16:02:50 -04:00
Andrei Paikin
d00501eabd
add usage of isEmpty method
2018-05-25 22:47:05 +03:00
John J. Aylward
dae88d7c5c
fix method names
2017-11-06 10:35:49 -05:00
John J. Aylward
08d93f3eb5
test cases for issue https://github.com/stleary/JSON-java/issues/379
2017-11-06 10:27:45 -05:00
John J. Aylward
dfa37a298f
Add more tests for unclosed arrays
2017-10-30 08:53:50 -04:00
John J. Aylward
bde6ba1c52
Updates exception expected message
2017-10-30 08:53:50 -04:00
John J. Aylward
52ecc89702
New test to verify unclosed array
2017-10-30 08:53:50 -04:00
John J. Aylward
0e612ba8a4
More test corrections for correct position reports in error messages
2017-06-21 19:56:00 -04:00
John J. Aylward
2867aaa8c8
Updates test cases to support new optFloat and optNumber
2017-05-17 12:33:59 -04:00
John J. Aylward
9df5d34bbe
* Update link in the README to the main JSON-Java repo
...
* Cleans up some warnings
* Adds new test for bug https://github.com/stleary/JSON-java/issues/332
* Adds some resource handling for string writers using pre-java1.7
support. I know StringWriters don't need a close method called, but the
tests should still handle their resources properly.
2017-04-27 12:39:42 -04:00
Sean Leary
c400de3cfe
Merge pull request #53 from run2000/master
...
valueToString() and write() tests
2016-08-10 21:55:33 -05:00
John J. Aylward
a2c311527b
Updates tests to include all opt methods and verify for missing keys.
2016-08-09 15:54:06 -04:00
Nicholas Cull
1246e12827
Factor out Writer from Appendable tests.
2016-07-24 19:39:52 +10:00
Nicholas Cull
ae77b5cd83
Tests for deep copy and mutability of toList() and toMap().
...
Both toMap() and toList() return deep copies, which are also mutable. That is, any changes to the JSONObject or JSONArray do not affect the newly create Map or List, and vice-versa. The resulting objects can be altered.
2016-07-23 22:51:50 +10:00
Nicholas Cull
72c2b911bf
Tests for toString(), write(), toList(), and toMap().
...
Explicitly test variations of toString() and write() for different indent levels, and different method overloads. Also create some tests for the new toList() and toMap() methods for coverage improvements to JSONArray and JSONObject.
2016-07-23 22:33:19 +10:00
John J. Aylward
c2de224711
Verify opt method conversions for JSONArray and JSONObject
2016-07-08 16:58:58 -04:00