Skip to content

chore(oxlint.config): enable 'vitest-js/padding-around-*' rules and add blank lines around test blocks and hooks - #610

Merged
sukvvon merged 1 commit into
mainfrom
chore/oxlint-vitest-js-padding-around
Dec 5, 2026
Merged

sukvvon merged 1 commit into
mainfrom
chore/oxlint-vitest-js-padding-around

Conversation

@sukvvon

@sukvvon sukvvon commented Dec 5, 2026 •

Copy link
Copy Markdown
Member

🎯 Changes

  • Enable the six vitest-js/padding-around-* rules (after-all-blocks, after-each-blocks, before-all-blocks, before-each-blocks, describe-blocks, test-blocks) in the test file override of oxlint.config.ts.
  • Add the blank lines these rules require between adjacent test blocks and hooks in:
    • packages/devtools-bundler-core/src/connection.test.ts
    • packages/devtools-bundler-core/src/inject-source.test.ts
    • packages/devtools-rspack/src/index.test.ts
    • packages/devtools/src/context/devtools-context.test.ts

✅ Checklist

  • I have followed the steps in the Contributing guide.
  • I have tested code changes locally with pnpm test:pr, or these tests do not apply to this pull request.
  • I fully understand the code in this pull request, including any code generated with AI assistance.

🚀 Release Impact

  • This change affects published code, and I have generated a changeset.
  • This change is docs/CI/dev-only (no release).

Summary by CodeRabbit

  • Chores

    • Added stricter formatting checks for test structure.
  • Tests

    • Improved spacing consistency across several test suites.
    • Removed a duplicate assertion; the remaining test coverage and behavior are unchanged.

@sukvvon sukvvon self-assigned this Dec 5, 2026
@changeset-bot

changeset-bot Bot commented Dec 5, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 83f1078

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai

coderabbitai Bot commented Dec 5, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The test-file lint override adds six padding rules. Test files gain blank lines, and one duplicate test is removed; its assertion remains in another test.

Changes: Test file consistency

Layer / File(s) Summary
Padding rules and test updates
oxlint.config.ts, packages/devtools-bundler-core/src/connection.test.ts, packages/devtools-bundler-core/src/inject-source.test.ts, packages/devtools-rspack/src/index.test.ts, packages/devtools/src/context/devtools-context.test.ts
The test-file override adds error-level padding rules for hooks, describe, and test blocks. Test files gain blank lines. A duplicate local-storage assertion test is removed; another test retains the assertion.

Estimated code review effort: 1 (Trivial) | ~4 minutes

Change: Other

Suggested reviewers: alemtuzlak

Merge Risk: Minimal · up to 83f10

This dev-only change enables lint padding rules for test files, adds blank lines to four test files, and removes one duplicate test. It does not affect runtime behavior or released code, and I found nothing that blocks merging.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: enabling the vitest-js padding-around rules in oxlint.config.ts and adding the blank lines these rules require around test blocks and hooks. It is a conventional-commi…
Description check Passed The description follows the template. It has the Changes section with the six rules and the four test files. The Checklist items are checked. The Release Impact section marks the change as docs/CI/dev…
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.
Full details: Title check

Explanation

The title names the main change: enabling the vitest-js padding-around rules in oxlint.config.ts and adding the blank lines these rules require around test blocks and hooks. It is a conventional-commit style title. It is long (112 characters), but it stays specific and matches the changeset.

Full details: Description check

Explanation

The description follows the template. It has the Changes section with the six rules and the four test files. The Checklist items are checked. The Release Impact section marks the change as docs/CI/dev-only. The template's first line of Changes has an HTML comment placeholder, which the author replaced with content. The description is complete and specific.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 3c2dbad and 83f1078.

Files selected for processing: 5

  • oxlint.config.ts
  • packages/devtools-bundler-core/src/connection.test.ts
  • packages/devtools-bundler-core/src/inject-source.test.ts
  • packages/devtools-rspack/src/index.test.ts
  • packages/devtools/src/context/devtools-context.test.ts

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.

@nx-cloud

nx-cloud Bot commented Dec 5, 2026 •

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit 83f1078

Command Status Duration Result
nx affected --targets=test:oxlint,test:sherif,t... ✅ Succeeded 3m 26s View ↗
nx run-many --target=test:e2e --parallel=1 --pr... ✅ Succeeded 1m 5s View ↗
nx run-many --targets=build --exclude=examples/... ✅ Succeeded 39s View ↗

💡 With Ultracache enabled, Nx Cloud learns each task's file inputs in CI and uses them on later runs. Turn on Ultracache in workspace settings ↗ · Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-12-05 01:55:37 UTC

@pkg-pr-new

pkg-pr-new Bot commented Dec 5, 2026

Copy link
Copy Markdown
More templates

@tanstack/angular-devtools

npm i https://pkg.pr.new/@tanstack/angular-devtools@610

@tanstack/devtools

npm i https://pkg.pr.new/@tanstack/devtools@610

@tanstack/devtools-a11y

npm i https://pkg.pr.new/@tanstack/devtools-a11y@610

@tanstack/devtools-bundler-core

npm i https://pkg.pr.new/@tanstack/devtools-bundler-core@610

@tanstack/devtools-client

npm i https://pkg.pr.new/@tanstack/devtools-client@610

@tanstack/devtools-rspack

npm i https://pkg.pr.new/@tanstack/devtools-rspack@610

@tanstack/devtools-ui

npm i https://pkg.pr.new/@tanstack/devtools-ui@610

@tanstack/devtools-utils

npm i https://pkg.pr.new/@tanstack/devtools-utils@610

@tanstack/devtools-vite

npm i https://pkg.pr.new/@tanstack/devtools-vite@610

@tanstack/devtools-webmcp

npm i https://pkg.pr.new/@tanstack/devtools-webmcp@610

@tanstack/devtools-event-bus

npm i https://pkg.pr.new/@tanstack/devtools-event-bus@610

@tanstack/devtools-event-client

npm i https://pkg.pr.new/@tanstack/devtools-event-client@610

@tanstack/preact-devtools

npm i https://pkg.pr.new/@tanstack/preact-devtools@610

@tanstack/react-devtools

npm i https://pkg.pr.new/@tanstack/react-devtools@610

@tanstack/solid-devtools

npm i https://pkg.pr.new/@tanstack/solid-devtools@610

@tanstack/svelte-devtools

npm i https://pkg.pr.new/@tanstack/svelte-devtools@610

@tanstack/vue-devtools

npm i https://pkg.pr.new/@tanstack/vue-devtools@610

commit: 83f1078

@sukvvon
sukvvon merged commit bd94643 into main Dec 5, 2026
11 checks passed
@sukvvon
sukvvon deleted the chore/oxlint-vitest-js-padding-around branch December 5, 2026 01:58
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