Fix NPE in EqConstList fixture reused by the store reloader test#306
Merged
Conversation
The equalator assertion added for the serializer round-trip test dereferenced getValue() unconditionally. The shared fixture is also driven by the store ReloaderSmokeTest, which reloads the root to its stored empty state, leaving value null and causing a NullPointerException. Guard the equalator check on a populated list so it still runs in the round-trip test but is skipped when the reloader resets to empty, matching the null-tolerant convention of the sibling EqBulkList fixture.
zdenek-jonas
approved these changes
Jul 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
EqConstListDatafixture (added in #304) asserts that the deserialized lists equalator survived serialization:This passes in the serializer round-trip test (
BasicSerializerTest), where the deserialized copy is fully populated. But the same fixture is reused by the store reposReloaderSmokeTest.reloadTypeTest, which:fillSampleData()without storing it,reloadDeep(...)resets the root back to its stored empty state (value == null),proveResults(...).In that flow
getValue()returnsnull, so the unconditionalcopy.getValue().equality()throws aNullPointerException, breaking the store integration tests (e.g. eclipse-store/store#764 CI, which builds against serializermain-SNAPSHOT).Fix
Guard the equalator assertion on a populated list. It still runs in the serializer round-trip test (where the list is filled), but is skipped when the reloader resets the root to its stored empty state — matching the null-tolerant convention already used by the sibling
EqBulkListDatafixture.Verification
BasicSerializerTeststill passes (70 tests, 0 failures) with the equalator assertion exercised for the populatedEqConstList, and the null-dereference that failed the store reloader test is eliminated.