Repository navigation
Conversation
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are blocking approval.
No open issues 🎉
What changed in this PR
Removes dead code and unused resources from the functional-test module without changing production code or JUnit-discovered tests.
Changes:
- Deletes unfinished methods without
@Testand obsolete commented-out test code. - Removes the associated database-disabling helper and unused query-options fixture.
- Deletes a stale comment about issue #347; query-option behavior is unchanged.
Paths below are relative to marklogic-client-api-functionaltests/src/test/java/com/marklogic/client/.
| File | Description |
|---|---|
functionaltest/queryoptions/collectionConstraintWithWordConstraintAndGoogleGrammarOpt.xml |
Deletes the unused query-options fixture. |
fastfunctest/TestQueryOptionBuilder.java |
Removes only the stale issue #347 comment block. |
fastfunctest/TestPOJOReadWriteWithTransactions.java |
Removes an undiscovered collection-search transaction test. |
fastfunctest/TestOpticOnLiterals.java |
Removes an unfinished built-in functions test. |
fastfunctest/TestAppServerConstraints.java |
Removes the undiscovered Google-grammar constraint test. |
datamovement/functionaltests/WriteHostBatcherTest.java |
Removes an unfinished database-disable test and its helper class. |
datamovement/functionaltests/StringQueryHostBatcherTest.java |
Removes an unfinished query-failure test and commented-out batcher contention test. |
Review effort: Balanced
|
Verified that removing these disabled/commented-out methods does not lose functional test coverage:
Minor note on Consider adding a quick check inside assertEquals(0, products.search(1, "even").getTotalSize());
assertEquals(55, products.search(1, t, "even").getTotalSize()); |
prgs-rsingh
left a comment
There was a problem hiding this comment.
Verified that all 7 removed dead test sites and orphaned fixtures are already covered by active tests and all CI/Jenkins checks are green.
This PR cleans up historical dead test debt across the test suite by permanently removing 7 dead code sites (unexecuted Early Access prototypes, unfinished plan builders, commented-out test stubs, orphaned batcher helpers, and obsolete comment banners) along with their unused imports and fixtures.
None of these sites were active tests in CI. Their removal eliminates codebase clutter and confusion with zero loss in test coverage.
Detailed Breakdown of Purged Dead Code Sites
StringQueryHostBatcherTest.java:741testQueryBatcherQueryFailures// @TestQueryBatcherTestandHostAvailabilityListenerTest.WriteHostBatcherTest.java:2170testDisableDBDuringInsert// @TestWriteBatcherFailureTestand activeWriteHostBatcherTestlistener suites.WriteHostBatcherTest.java(Additional site / Orphaned helper)
testDisableDBDuringInsertwas purged; removed to keep-Werrorclean.TestOpticOnLiterals.java:1093testBuiltInFns@Test, zero assertions)OpticOnLiteralsTest,OpticPlanTest, andPlanGeneratedTest.TestAppServerConstraints.java:155testWithWordConstraintAndGoogleGrammarSearchQueryDefinitionTestandTestQueryOptionBuilder.TestPOJOReadWriteWithTransactions.java:294test4POJOSearchWithCollectionsandTransaction@Test, never run)PojoRepositoryTest.TestQueryOptionBuilder.java:1768(Comment block only)
Begin/End) referencing tests deleted before 4.0.2TestQueryOptionBuilder. Active test logic was preserved to avoid conflict with MLE-32873.