ADDITIONAL SYSTEM INFORMATION : Operating System: darwin 24.6.0 (macOS) JDK Version: openjdk version "21" 2023-09-19 LTS Build: OpenJDK Runtime Environment (build 21+35-LTS) Architecture: x86_64 Additional Information: - Working on OpenJDK JDK repository - Testing with jtreg test framework A DESCRIPTION OF THE PROBLEM : I would like to contribute to OpenJDK by adding comprehensive edge case tests for Objects.requireNonNull, requireNonNullElse, and requireNonNullElseGet methods to improve test coverage. Motivation: The current test suite for Objects.requireNonNull methods covers basic cases but lacks edge case coverage. This enhancement will improve the overall test quality and help ensure API correctness. Proposed Changes: - Add test for requireNonNull with null Supplier parameter - Add test for requireNonNull with Supplier throwing exception - Add test for requireNonNullElse with both arguments null - Add test for requireNonNullElseGet with null supplier - Add test for requireNonNullElseGet with supplier returning null Testing: All new tests will be added to test/jdk/java/util/Objects/ BasicObjectsTest.java following jtreg test format. This is my first contribution to OpenJDK. I'm ready to submit a pull request once a JBS issue is created.
|