Skip to content

Wheels cli fixes#1683

Merged
zainforbjs merged 9 commits intodevelopfrom
wheels-cli-fixes
Aug 20, 2025
Merged

Wheels cli fixes#1683
zainforbjs merged 9 commits intodevelopfrom
wheels-cli-fixes

Conversation

@zainforbjs
Copy link
Copy Markdown
Contributor

No description provided.

- Added new `wheels test coverage` command to run tests with coverage reporting.
- Implemented the core functionality to execute the test suite and generate coverage output.
- Options and flags (e.g., --html, --threshold) are in progress and will be completed in upcoming commits.
- Command is functional but not yet finalized for all available options.
Refactored test command components to eliminate code duplication and improve maintainability:

- Extracted shared test execution logic into base.cfc component
  - Added executeTestRequest() for HTTP test requests
  - Added buildTestUrl() to construct test URLs with proper server configuration
  - Added parseTestResponse() for handling different response formats
  - Added getServerConfig() to retrieve actual running server host/port
  - Added helper functions for coverage processing and formatting

- Updated coverage.cfc to use base functions
  - Replaced inline HTTP execution with executeTestRequest()
  - Replaced URL building logic with buildTestUrl()
  - Maintained all existing coverage reporting functionality

- Updated run.cfc (test runner) to use base functions
  - Replaced duplicate HTTP and URL building code
  - Added proper test output formatting matching legacy format
  - Fixed response structure compatibility issues
  - Added support for different TestBox response formats

- Updated legacy run.cfc to use base functions
  - Maintained backward compatibility
  - Replaced inline implementations with base function calls

This refactoring reduces code duplication across test commands while maintaining
full backward compatibility and existing functionality.
Updated test directory path to ensure new test files are detected and executed.
- Added real time processor for "wheels analyze code"
- Updated guides for "wheels assets" commands
- Removed watch options from run command as its already a sub command available "wheels test watch"
- Deleted test.cfc as its now converted into new command "wheels test run", existence of this file was creating issue to run sub commands in test folder.
- Guides updated according to current working of commands
- Removed extra functions in base.cfc
- Restored test.cfc as the latest code for "wheels test run" not functional.
@zainforbjs zainforbjs marked this pull request as ready for review August 20, 2025 14:57
@zainforbjs zainforbjs merged commit 9a382ff into develop Aug 20, 2025
31 checks passed
@zainforbjs zainforbjs deleted the wheels-cli-fixes branch August 20, 2025 15:02
@zainforbjs zainforbjs restored the wheels-cli-fixes branch August 22, 2025 13:47
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