Skip to content

test: reset the field separator in ExistsFilterTest - #1323

Merged
anidotnet merged 1 commit into
mainfrom
fix/exists-filter-test-separator
Oct 5, 2026
Merged

anidotnet merged 1 commit into
mainfrom
fix/exists-filter-test-separator

Conversation

@anidotnet

@anidotnet anidotnet commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

ExistsFilterTest.testEmbeddedField fails on the Ubuntu runner, which broke the build of #1320, #1321 and #1322.

Cause: NitriteConfig.fieldSeparator is static. NitriteConfigTest and NitriteBuilderTest set it to "Separator" / "::" and never restore it; when they run before ExistsFilterTest (as on Ubuntu), address.city is not treated as an embedded path.

Reproduced locally with -Dtest=NitriteConfigTest,ExistsFilterTest -Dsurefire.runOrder=alphabetical; passes with the fix. The test now resets the separator in @Before, as DocumentTest does.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Tests
    • Reset the field separator before each existence-filter test to keep test results consistent.

NitriteConfig.fieldSeparator is static. NitriteConfigTest and NitriteBuilderTest
leave it as "Separator" / "::", and when they run first (as on the Ubuntu
runner) testEmbeddedField cannot resolve "address.city". This failed the
build of every open PR.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

🧰 Additional context used
📚 Code guidelines (1)
.github/copilot-instructions.md — auto-discovered

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 1b9e1280-d6ca-4b65-b2d7-4e3787d32d51
📥 Commits

Reviewing files that changed from the base of the PR and between e4623c8 and 5f2e81a.

📒 Files selected for processing (1)
  • nitrite/src/test/java/org/dizitart/no2/filters/ExistsFilterTest.java

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.


📝 Walkthrough

Walkthrough

The ExistsFilterTest class now resets the static field separator to "." before each test. The test cases are unchanged.

Changes

Exists filter tests

Layer / File(s) Summary
Reset field separator
nitrite/src/test/java/org/dizitart/no2/filters/ExistsFilterTest.java
A @Before setup method sets the field separator to "." before each test. The test cases are unchanged.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to 5f2e8

This test-fixture change introduces no supported merge-blocking risk; production behavior is unchanged.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the change: resetting the field separator in ExistsFilterTest.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@anidotnet
anidotnet merged commit f8af950 into main Oct 5, 2026
12 checks passed
@anidotnet
anidotnet deleted the fix/exists-filter-test-separator branch October 5, 2026 05:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant