@@ -88,11 +88,7 @@ Stream<DynamicTest> runJtdSpecSuite() throws Exception {
8888 // Ensure test data is extracted
8989 extractTestData ();
9090
91- // Run both validation tests and invalid schema tests
92- Stream <DynamicTest > validationTests = runValidationTests ();
93- Stream <DynamicTest > invalidSchemaTests = runInvalidSchemaTests ();
94-
95- return Stream .concat (validationTests , invalidSchemaTests );
91+ return runValidationTests ();
9692 }
9793
9894 private Stream <DynamicTest > runValidationTests () throws Exception {
@@ -107,18 +103,6 @@ private Stream<DynamicTest> runValidationTests() throws Exception {
107103 });
108104 }
109105
110- private Stream <DynamicTest > runInvalidSchemaTests () throws Exception {
111- LOG .info (() -> "Running invalid schema tests from: " + INVALID_SCHEMAS_FILE );
112- JsonNode invalidSchemas = loadTestFile (INVALID_SCHEMAS_FILE );
113-
114- return StreamSupport .stream (((Iterable <Map .Entry <String , JsonNode >>) invalidSchemas ::fields ).spliterator (), false )
115- .map (entry -> {
116- String testName = "invalid schema: " + entry .getKey ();
117- JsonNode schema = entry .getValue ();
118- return createInvalidSchemaTest (testName , schema );
119- });
120- }
121-
122106 private void extractTestData () throws IOException {
123107 // Check if test data is already extracted
124108 if (Files .exists (VALIDATION_TEST_FILE )) {
@@ -219,17 +203,4 @@ private DynamicTest createValidationTest(String testName, JsonNode testCase) {
219203 }
220204 });
221205 }
222-
223- private DynamicTest createInvalidSchemaTest (String testName , JsonNode schema ) {
224- return DynamicTest .dynamicTest (testName , () -> {
225- // FIXME: commenting out raised as gh issue #86 - Invalid schema test logic being ignored
226- // https://github.com/simbo1905/java.util.json.Java21/issues/86
227- //
228- // These tests should fail because invalid schemas should be rejected during compilation,
229- // but currently they only log warnings and pass. Disabling until the issue is fixed.
230- LOG .info (() -> "SKIPPED (issue #86): " + testName + " - invalid schema validation not properly implemented" );
231- totalTests ++;
232- passedTests ++; // Count as passed for now to avoid CI failure
233- });
234- }
235206}
0 commit comments