Skip to content

Conversation

@simbo1905
Copy link
Owner

Fixes #1

Summary

  • Added comprehensive documentation to README.md explaining the fromUntyped() and toUntyped() conversion utilities
  • Created JsonTypedUntypedTests with full test coverage for both methods
  • Tests cover all type conversions, edge cases, and round-trip conversion

Changes

  • README.md: Added "Type Conversion Utilities" section with examples and type mappings
  • JsonTypedUntypedTests.java: New test class with 11 test methods covering:
    • Simple type conversions (String, Number, Boolean, null)
    • BigInteger and BigDecimal support
    • Collection conversions (List, Map)
    • Nested structures
    • Round-trip conversion preservation
    • Error cases (invalid types, non-String map keys)

Test Results

All 14 tests pass successfully across JDK 21, 22, 23, and 24.

Added comprehensive documentation for the Json.fromUntyped() and Json.toUntyped()
methods that provide bidirectional conversion between JsonValue objects and
standard Java collections/types. Includes usage examples and type mappings.
- Created JsonTypedUntypedTests with full coverage of Json.fromUntyped() and Json.toUntyped()
- Tests simple types, collections, nested structures, edge cases, and round-trip conversion
- Added .mvn directory to fix mvnd warning about root directory
- Fixed generic type issues with List<?> by using @SuppressWarnings and proper casting
- Corrected numeric type expectations (Integer boxed to Long in JsonNumber)
- All 14 tests now pass successfully
- Added explicit PR event types: opened, synchronize, reopened
- Ensures checks run when PRs are created or updated
@simbo1905 simbo1905 merged commit 971b729 into main Jul 25, 2025
4 checks passed
@simbo1905 simbo1905 deleted the feature/typed-untyped-conversion branch July 25, 2025 08:19
simbo1905 pushed a commit that referenced this pull request Aug 22, 2025
* Document type conversion utilities (fromUntyped/toUntyped)

Added comprehensive documentation for the Json.fromUntyped() and Json.toUntyped()
methods that provide bidirectional conversion between JsonValue objects and
standard Java collections/types. Includes usage examples and type mappings.

* Add comprehensive tests for typed/untyped conversion utilities

- Created JsonTypedUntypedTests with full coverage of Json.fromUntyped() and Json.toUntyped()
- Tests simple types, collections, nested structures, edge cases, and round-trip conversion
- Added .mvn directory to fix mvnd warning about root directory

* Fix JsonTypedUntypedTests compilation and test failures

- Fixed generic type issues with List<?> by using @SuppressWarnings and proper casting
- Corrected numeric type expectations (Integer boxed to Long in JsonNumber)
- All 14 tests now pass successfully

* Update GitHub Actions to trigger on PR events

- Added explicit PR event types: opened, synchronize, reopened
- Ensures checks run when PRs are created or updated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add documentation and tests for typed/untyped conversion utilities

2 participants