bee0511 opened a new pull request, #462: URL: https://github.com/apache/atlas/pull/462
## What changes were proposed in this pull request? The test `AtlasJanusGraphIndexClientTest#testGetTopTermsRandom4` failed intermittently because `HashMap` iteration order is non-deterministic. Changed `generateTerms(...)` to use `LinkedHashMap` so iteration order is consistent. This is a **test-only** change. ## How was this patch tested? * Reproduced flaky failures with [NonDex](https://github.com/TestingResearchIllinois/NonDex), a tool that systematically perturbs iteration order to expose order-dependent bugs. * Example command: ```bash mvn -pl graphdb/janus edu.illinois:nondex-maven-plugin:2.1.7:nondex \ -Dtest=org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest#testGetTopTermsRandom4 \ -Drat.skip ``` * Before fix: ``` [INFO] Running org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest [ERROR] Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.806 s <<< FAILURE! - in org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest [ERROR] org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest.testGetTopTermsRandom4 Time elapsed: 0.423 s <<< FAILURE! java.lang.AssertionError: expected [8] but found [7] at org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest.assertOrder(AtlasJanusGraphIndexClientTest.java:143) at org.apache.atlas.repository.graphdb.janus.AtlasJanusGraphIndexClientTest.testGetTopTermsRandom4(AtlasJanusGraphIndexClientTest.java:99) ``` * After fix: test passes consistently under repeated NonDex runs. -- 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]
