You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "ai-yang (via GitHub)" <gi...@apache.org> on 2026/08/02 03:05:25 UTC
[I] [Studio][CI] Run frontend tests and lint checks in GitHub Actions [rocketmq-dashboard]
ai-yang opened a new issue, #754:
URL: https://github.com/apache/rocketmq-dashboard/issues/754
## Affected branch
`rocketmq-studio` at `bbf1b7e0cf25a5065ba049b5450cc8155569f710`.
## Current behavior
The repository's only GitHub Actions workflow installs the Studio frontend dependencies and runs `npm run build`. The frontend Docker image also runs only `npm ci` and `npm run build`.
However, `web/package.json` defines three independent commands:
- `build`: `tsc -b && vite build`
- `test`: `vitest run`
- `lint`: `eslint .`
Neither TypeScript/Vite compilation nor the Docker build executes the Vitest suite or ESLint, so a pull request can have failing behavior assertions or lint errors while every configured frontend check remains green.
## Confirmed impact
This has already allowed broken tests to reach `rocketmq-studio`:
- PR #479 added a BrokerCluster page that rendered `Broker 集群` / `创建集群`, while its tests asserted `RocketMQ 集群` / `新建集群`. Its `Frontend Build (Node 20)` check succeeded and the PR was merged.
- PR #474 added an audit-log mock using `data.list` while asserting `result.items`; its frontend build check also succeeded and the PR was merged.
- PR #498 later corrected both sets of baseline assertions. Although that PR reports manual `npm test`, `npm run lint`, and `npm run build` verification, its required check rollup contained only backend and frontend build jobs.
The current Node 20 baseline is healthy (63 Vitest files / 265 tests; ESLint 0 errors with 4 existing warnings; production build succeeds), so test and lint error gates can be enabled without first repairing a red baseline. The existing warnings mean this issue should not implicitly require `--max-warnings=0`; warning policy can be decided separately.
## Controlled reproduction
On the latest unmodified `rocketmq-studio` baseline, I added two research-only sentinels that are not part of any proposed commit:
- a Vitest assertion that deliberately fails whenever Vitest executes; and
- a TypeScript file containing `debugger`, which the current ESLint configuration reports as a `no-debugger` error.
Under Node 20:
- the sentinel Vitest failed in 5/5 isolated processes at the intended assertion;
- `npm run lint` failed with exactly 1 error (plus the 4 existing warnings); but
- the workflow's current `npm run build` command still succeeded and transformed 7,979 modules while both sentinels were present.
This directly demonstrates that the configured frontend build check does not execute either existing quality gate. The research-only files remain untracked and must never be committed.
## Expected behavior
Pull requests targeting `rocketmq-studio` should be unable to pass CI when:
1. `npm test` fails; or
2. `npm run lint` reports an error.
The existing production build and frontend Docker build coverage should remain in place.
## Proposed CI change
After `npm ci`, run the existing package scripts under Node 20:
```text
npm test
npm run lint
npm run build
```
These may be steps in the current frontend job or separate named jobs. Separate jobs improve failure visibility and parallelism, while adding steps preserves the existing required-check name. Maintainer guidance is requested before changing workflow/check names because branch-protection configuration is outside the repository and cannot be inferred from the YAML.
## Acceptance criteria
- A deliberately failing Vitest assertion makes the frontend CI fail.
- An ESLint error makes the frontend CI fail.
- The current `rocketmq-studio` baseline passes both commands.
- `Frontend Build (Node 20)` and `Frontend Docker Build` coverage is retained.
- Existing lint warnings are reported but do not become failures unless maintainers explicitly choose a zero-warning policy.
## Scope
This issue is limited to the Studio frontend test and lint gates. The backend workflow's test policy can be discussed separately to keep this change atomic.
Dedupe note (refreshed 2026-08-02): immediate searches across open/closed issues and open/closed/merged PRs for CI/workflow/frontend tests/Vitest/ESLint/npm test/npm lint found no equivalent or claimed work. #430 created the compile-only workflow; #500 added only the Docker build; #498 changed tests, not CI.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Studio][CI] Run frontend tests and lint checks in GitHub Actions [rocketmq-dashboard]
Posted by "RockteMQ-AI (via GitHub)" <gi...@apache.org>.
RockteMQ-AI commented on issue #754:
URL: https://github.com/apache/rocketmq-dashboard/issues/754#issuecomment-5192812660
**Issue Evaluation**
Category: `enhancement` | Status: **Evaluated**
Adding frontend tests and lint checks to GitHub Actions is a standard CI improvement. This ensures code quality gates are enforced on every PR.
**Feasibility:** Feasible. The frontend likely already has test/lint scripts configured (Vitest, ESLint). Adding a CI job to run them is straightforward.
---
*Automated evaluation by RockteMQ-AI*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Studio][CI] Run frontend tests and lint checks in GitHub Actions [rocketmq-dashboard]
Posted by "yyqdbngt (via GitHub)" <gi...@apache.org>.
yyqdbngt commented on issue #754:
URL: https://github.com/apache/rocketmq-dashboard/issues/754#issuecomment-5186835097
I would like to work on this. I will keep the existing frontend build and Docker checks, add the current Vitest and ESLint commands under Node 20, and verify that lint warnings remain non-fatal.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Studio][CI] Run frontend tests and lint checks in GitHub Actions [rocketmq-dashboard]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #754:
URL: https://github.com/apache/rocketmq-dashboard/issues/754#issuecomment-5274318953
This issue has been automatically closed because there has been no activity for 7 days. If you believe this issue is still relevant, please reopen it with updated information.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Studio][CI] Run frontend tests and lint checks in GitHub Actions [rocketmq-dashboard]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #754: [Studio][CI] Run frontend tests and lint checks in GitHub Actions
URL: https://github.com/apache/rocketmq-dashboard/issues/754
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org