gnodet-bot commented on code in PR #29354:
URL: https://github.com/apache/camel/pull/29354#discussion_r4496675056


##########
components/camel-pqc/pom.xml:
##########
@@ -35,6 +35,7 @@
     <properties>
         <skipITs.s390x>true</skipITs.s390x>
         <skipITs.ppc64le>true</skipITs.ppc64le>
+        <camel.surefire.parallel>true</camel.surefire.parallel>

Review Comment:
   ⚠️ **Race condition: three test classes write to the same `keystore.jks` 
filename.**
   
   `PQCSignatureOnlyKeyStoreTest`, `PQCSignatureSLHDSAKeystoreTest`, and 
`PQCSignatureWithKeyStoreTest` all use `new FileOutputStream("keystore.jks")` 
and `Files.deleteIfExists(Path.of("keystore.jks"))` in the working directory. 
With `camel.surefire.parallel=true` and `mode.classes.default = concurrent`, 
these classes run simultaneously in the same JVM and share the working 
directory.
   
   One class's `@AfterAll teardown()` deleting `keystore.jks` while another's 
`@BindToRegistry setKeyStore()` is still writing to it → 
`FileNotFoundException` or corrupted write. This will produce intermittent CI 
failures.
   
   `PQCKeyStoreJdk25KeyConversionTest` already solves this correctly with a 
unique filename (`keystore-jdk25-test.jks`). Apply the same pattern:
   - `PQCSignatureOnlyKeyStoreTest` → `keystore-mldsa-test.jks`
   - `PQCSignatureSLHDSAKeystoreTest` → `keystore-slhdsa-test.jks`  
   - `PQCSignatureWithKeyStoreTest` → `keystore-with-key-test.jks`
   
   Alternatively, migrate these tests to use `@TempDir` (the idiomatic JUnit 5 
approach), which eliminates the shared-state problem entirely.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to