-
-
Notifications
You must be signed in to change notification settings - Fork 18
feat(vscode): continuous run #814
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
✅ Deploy Preview for rstest-dev ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds continuous run/watch mode support to the VSCode extension, allowing tests to automatically re-run when files change. The implementation adds a new onTestRunStart lifecycle hook to the reporter interface and updates the VSCode extension to support continuous test execution.
- Added
onTestRunStartlifecycle hook to the Reporter interface for notifying when a test run begins - Implemented continuous/watch mode by passing
command: 'watch'to the test worker and managing multiple test run cycles - Refactored test run management to create new TestRun objects for subsequent runs in watch mode
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| website/docs/zh/api/javascript-api/reporter.mdx | Added onTestRunStart to the list of run-level hooks in Chinese documentation |
| website/docs/en/api/javascript-api/reporter.mdx | Added onTestRunStart to the list of run-level hooks in English documentation |
| packages/vscode/tests/suite/progress.test.ts | Refactored test suite to support testing continuous run mode; added new test case for continuous run behavior |
| packages/vscode/tests/fixtures/workspace-1/test/progress.test.ts | Updated test fixture values to match test expectations |
| packages/vscode/src/worker/reporter.ts | Added onTestRunStart and onTestRunEnd implementations; added onCoverageEnd support |
| packages/vscode/src/worker/index.ts | Reordered reporters to ensure default reporter output is flushed before progress reporter |
| packages/vscode/src/types.ts | Added 'watch' command type to support continuous run mode |
| packages/vscode/src/testRunReporter.ts | Implemented logic to create new test runs for subsequent cycles in continuous mode |
| packages/vscode/src/master.ts | Updated runTest to support continuous mode with promise-based completion tracking |
| packages/vscode/src/extension.ts | Enabled continuous mode for all run profiles; updated to pass createTestRun function for creating subsequent runs |
| packages/core/src/types/reporter.ts | Added onTestRunStart lifecycle hook to Reporter interface |
| packages/core/src/pool/forks.ts | Removed SIGTERM handler cleanup code |
| packages/core/src/core/runTests.ts | Added call to onTestRunStart for all reporters before running tests |
| packages/core/src/core/rstest.ts | Simplified reporters type from union to just Reporter |
| packages/core/src/core/globalSetup.ts | Removed SIGTERM handler cleanup code |
| e2e/reporter/rstest.customReporterConfig.ts | Added onTestRunStart implementation to custom reporter |
| e2e/reporter/index.test.ts | Added assertion to verify onTestRunStart is called |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
👍 |
Summary
20251229-235944.mp4
Related Links
Checklist