Skip to content

refactor(integration-tests): Deprecate clp_mode_utils and adopt package-specific mode utilities; remove problematic running-mode validation for clp-presto and clp-json-s3 tests.#2243

Open
quinntaylormitchell wants to merge 2 commits intoy-scope:mainfrom
quinntaylormitchell:testing-migration-modes

Conversation

@quinntaylormitchell
Copy link
Copy Markdown
Collaborator

@quinntaylormitchell quinntaylormitchell commented May 4, 2026

Description

This PR deprecates the clp_mode_utils module in favour of the mode descriptions from tests/package_tests/clp_*/utils/mode.py.

Checklist

  • The PR satisfies the contribution guidelines.
  • This is a breaking change and that has been indicated in the PR title, OR this isn't a
    breaking change.
  • Necessary docs have been updated, OR no docs need to be updated.

Validation performed

Ran uv run pytest -m 'package' and uv run pytest -m 'core'; all tests pass.

Summary by CodeRabbit

  • Tests

    • Updated test infrastructure to consolidate configuration management and simplified validation logic across test modules.
  • Chores

    • Removed log ingestor component from the clp-json operating mode configuration.
    • Reorganized internal testing utilities for improved maintainability.

@quinntaylormitchell quinntaylormitchell requested a review from a team as a code owner May 4, 2026 20:28
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 4, 2026

Walkthrough

This PR refactors the test infrastructure to simplify validation logic. Mode configurations are consolidated into dedicated utility modules, the validation function is renamed and streamlined to check only running Docker services (removing mode config correctness checks), and unused utility functions are removed.

Changes

Test Infrastructure Refactoring

Layer / File(s) Summary
Mode Configuration Consolidation
integration-tests/tests/package_tests/clp_json/test_clp_json.py, integration-tests/tests/package_tests/clp_text/test_clp_text.py
CLP_JSON_MODE and CLP_TEXT_MODE are now imported from dedicated utils.mode modules instead of being constructed locally via PackageModeConfig.
Component List Updates
integration-tests/tests/package_tests/clp_json/utils/mode.py
CLP_LOG_INGESTOR_COMPONENT is removed from the import list and the CLP_JSON_MODE component tuple.
Validation Function Refactoring
integration-tests/tests/utils/asserting_utils.py
validate_package_instance is renamed to validate_package_running and simplified to verify only that required Docker Compose services are running; mode config validation logic and related imports (ClpConfig, YAML parsing, signature comparison) are removed.
Test Updates
integration-tests/tests/package_tests/clp_json/test_clp_json.py, integration-tests/tests/package_tests/clp_text/test_clp_text.py
Test assertions are updated to call the renamed validate_package_running instead of validate_package_instance in startup, compression, and search tests.
Utility Cleanup
integration-tests/tests/utils/clp_mode_utils.py
The entire module is removed; it previously exported CLP component constants and a mode signature comparison function that are no longer needed.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
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.
Title check ✅ Passed The title accurately describes the main change: deprecating clp_mode_utils and adopting package-specific mode utilities, with removal of running-mode validation for specific test packages.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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 and usage tips.

Copy link
Copy Markdown
Contributor

@Bill-hbrhbr Bill-hbrhbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For title, how about:

refactor(integration-tests): Deprecate `clp_mode_utils` and adopt package-specific mode utilities; Remove problematic running-mode validation for `clp-presto` and `clp-json-s3` tests.

@quinntaylormitchell quinntaylormitchell changed the title refactor(integration-tests): Deprecate clp_mode_utils module. refactor(integration-tests): Deprecate clp_mode_utils and adopt package-specific mode utilities; Remove problematic running-mode validation for clp-presto and clp-json-s3 tests. May 5, 2026
@quinntaylormitchell quinntaylormitchell changed the title refactor(integration-tests): Deprecate clp_mode_utils and adopt package-specific mode utilities; Remove problematic running-mode validation for clp-presto and clp-json-s3 tests. refactor(integration-tests): Deprecate clp_mode_utils and adopt package-specific mode utilities; remove problematic running-mode validation for clp-presto and clp-json-s3 tests. May 5, 2026
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.

3 participants