Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Won't Fix
-
None
Description
Test `testKeyedMapStateUpgrade` depends on `put` in `HeapMapState.java` and `deserialize` in `MapSerializer.java`. It has this following test assertion `assertEquals((Integer) 1, actual.getKey());` that asserts the `getKey()` value of `actual`. However the `HashMap` in `put` and `deserialize` does not guarantee any specific order of entries. Therefore, the assertion will fail if the order is different.
This PR proposes to use `LinkedHashMap` for a deterministic order. Please let me know if you want to discuss the changes more.
Attachments
Issue Links
- links to