Skip to content

test(vite): satisfy prefer-expect-assertions on studio-plugin test - #178

Merged
prisis merged 2 commits into
alphafrom
chore/fix-studio-test-assertions
Jul 22, 2026
Merged

prisis merged 2 commits into
alphafrom
chore/fix-studio-test-assertions

Conversation

@prisis

@prisis prisis commented Jul 22, 2026

Copy link
Copy Markdown
Member

Follow-up to #172: restore expect.hasAssertions() as the first expression of the studio-plugin ETag test (the unconditional expect([200,501]) guarantees ≥1 assertion, so it's safe on the unbuilt-studio path). Clears a vitest/prefer-expect-assertions warning that fails Lint (eslint) (--max-warnings=0) on any PR making @lunora/vite affected — currently blocking #173/#174.

🤖 Generated with Claude Code

#172 replaced `expect.hasAssertions()` with an unconditional
`expect([200, 501])` to survive the unbuilt-studio (501) path, but that trips
`vitest/prefer-expect-assertions` (fails under --max-warnings=0 whenever a PR
makes @lunora/vite affected). Restore `expect.hasAssertions()` as the first
expression — now safe because the unconditional assertion guarantees ≥1 on
every path — satisfying both the rule and the 501 environment.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0197KjhmBDB3PXAc6TXiPqZ9
@netlify

netlify Bot commented Jul 22, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for lunorash ready!

Name Link
🔨 Latest commit 1b83cd0
🔍 Latest deploy log https://app.netlify.com/projects/lunorash/deploys/6a60fb590cf2ff0008dd38a0
😎 Deploy Preview https://deploy-preview-178--lunorash.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai

coderabbitai Bot commented Jul 22, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Review was skipped due to path filters

⛔ Files ignored due to path filters (1)
  • packages/vite/__tests__/studio-plugin.test.ts is excluded by !**/__tests__/**, !**/*.test.ts and included by packages/**

CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including **/dist/** will override the default block on the dist directory, by removing the pattern from both the lists.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5989734a-76e1-40da-ac5f-44a3808d36a7

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/fix-studio-test-assertions

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.

@prisis
prisis enabled auto-merge July 22, 2026 17:01
@github-actions

Copy link
Copy Markdown
Contributor

Thank you for following the naming conventions! 🙏

@github-actions

Copy link
Copy Markdown
Contributor

Thank you for confirming the Contributor License Agreement! 🙏

@codspeed

codspeed Bot commented Jul 22, 2026 •

Copy link
Copy Markdown

This PR has no benchmarks

⚠️ No benchmarks were detected in both the base of the PR and the PR.
Please ensure that your benchmarks are correctly instrumented with CodSpeed.

Check out the benchmarks creation guide


Comparing chore/fix-studio-test-assertions (1b83cd0) with alpha (cace8e5)1

Open in CodSpeed

Footnotes

  1. No successful run was found on alpha (33838f9) during the generation of this report, so cace8e5 was used instead as the comparison base. There might be some changes unrelated to this pull request in this report. ↩

@prisis
prisis added this pull request to the merge queue Jul 22, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jul 22, 2026
@prisis
prisis merged commit c62d862 into alpha Jul 22, 2026
12 checks passed
@prisis
prisis deleted the chore/fix-studio-test-assertions branch July 22, 2026 17:18
@github-actions

github-actions Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using our GitHub Discussions tab for questions.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Sep 8, 2026

This branch was previously deployed

1 inactive deployment
benchmarks — 1b83cd0e Deployed Jul 22, 2026 by prisis via Benchmarks #882
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant