Skip to content

test: stop two fixtures racing the work they are checking - #1548

Merged
danielroe merged 3 commits into
mainfrom
test/fixture-races
Sep 21, 2026
Merged

danielroe merged 3 commits into
mainfrom
test/fixture-races

Conversation

@danielroe

Copy link
Copy Markdown
Member

🔗 Linked issue

📚 Description

small test fixture improvement

@danielroe
danielroe enabled auto-merge September 21, 2026 22:29
@pkg-pr-new

pkg-pr-new Bot commented Sep 21, 2026

Copy link
Copy Markdown
  • nuxt-cli-playground

    npm i https://pkg.pr.new/create-nuxt@1548
    
    npm i https://pkg.pr.new/nuxi@1548
    
    npm i https://pkg.pr.new/@nuxt/cli@1548
    

commit: 8bb0182

@github-actions

github-actions Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

CLI benchmark

@nuxt/cli v4.0.0-alpha.1 (baseline) vs v4.0.0-alpha.1 (this PR)

Metric baseline v4.0.0-alpha.1 head v4.0.0-alpha.1 Delta
nuxt --version wall time (median) 66 ms 65 ms -1.1%
nuxt --help wall time (median) 143 ms 144 ms +0.6%
nuxt dev --help wall time (median) 108 ms 108 ms -0.4%
nuxt --version modules loaded 37 37 0.0%
nuxt --help modules loaded 139 139 0.0%
nuxt dev --help modules loaded 82 82 0.0%
Installed node_modules 2.38 MB 2.38 MB +0.0%
Published tarball (packed) 231.7 kB 231.9 kB +0.1%
Full report

@nuxt/cli v4.0.0-alpha.1 (baseline) vs v4.0.0-alpha.1 (head)

Setting Value
Baseline ref:9cb3b3025b94b64acee0fd878c88a199deefc616 (v4.0.0-alpha.1)
Head local packages/nuxt-cli at 46e3862 (v4.0.0-alpha.1)
Node v24.21.0
OS Linux 6.17.0 (kernel 6.17.0-1022-azure)
CPU AMD EPYC 7763 64-Core Processor x 4
Memory 15.6 GB
Load average at start 0.84, 0.26, 0.09
Run started 2026-09-21T23:20:11.118Z

Cold CLI startup

Median of 15 interleaved runs per command, one warmup discarded.

Command baseline v4.0.0-alpha.1 median head v4.0.0-alpha.1 median Delta baseline v4.0.0-alpha.1 min / p95 head v4.0.0-alpha.1 min / p95
nuxt --version 66 ms 65 ms -1.1% 63 ms / 68 ms 62 ms / 70 ms
nuxt --version (first output byte) 61 ms 61 ms -1.0% 59 ms / 63 ms 58 ms / 65 ms
nuxt --help 143 ms 144 ms +0.6% 139 ms / 147 ms 141 ms / 146 ms
nuxt --help (first output byte) 137 ms 139 ms +1.1% 133 ms / 141 ms 136 ms / 141 ms
nuxt dev --help 108 ms 108 ms -0.4% 103 ms / 110 ms 104 ms / 113 ms
nuxt dev --help (first output byte) 104 ms 103 ms -0.7% 98 ms / 105 ms 99 ms / 108 ms
nuxt <unknown-command> (no-op) 153 ms 153 ms -0.1% 148 ms / 161 ms 149 ms / 155 ms
nuxt <unknown-command> (no-op) (first output byte) 148 ms 148 ms -0.1% 142 ms / 155 ms 144 ms / 150 ms

Module load cost

Counted with a module.registerHooks load hook, compile cache disabled. Counts every JS module actually evaluated on that code path (built-ins excluded, native addons excluded).

Command baseline v4.0.0-alpha.1 modules head v4.0.0-alpha.1 modules Delta baseline v4.0.0-alpha.1 source bytes head v4.0.0-alpha.1 source bytes Delta
nuxt --version 37 37 0.0% 302.8 kB 302.8 kB 0.0%
nuxt --help 139 139 0.0% 1.04 MB 1.04 MB 0.0%
nuxt dev --help 82 82 0.0% 646.3 kB 646.3 kB 0.0%

Install footprint and published tarball

Each version installed on its own into an empty project with nothing but @nuxt/cli as a dependency, so the tree is exactly the CLI and its transitive dependencies. npm cache is warm and the registry is only consulted for metadata, so install wall time is indicative, not a network benchmark.

Metric baseline v4.0.0-alpha.1 head v4.0.0-alpha.1 Delta
Direct dependencies of @nuxt/cli 22 22 0.0%
Packages in the installed tree (unique name@version) 38 38 0.0%
Unique package names 38 38 0.0%
Package directories on disk (cross-check) 31 31 0.0%
Installed node_modules on disk 2.38 MB 2.38 MB +0.0%
Installed files 407 407 0.0%
Install wall time (warm npm cache, median of 3) 1.28 s 1.34 s +5.2%
Published tarball (packed) 231.7 kB 231.9 kB +0.1%
Published tarball (unpacked) 756.7 kB 757.2 kB +0.1%
Files in tarball 84 84 0.0%

Interleaved runs on a shared runner: trust the deltas, not the absolute timings. The dev, restart and build suites run locally via pnpm bench:cli.

@codspeed

codspeed Bot commented Sep 21, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 2 untouched benchmarks


Comparing test/fixture-races (886f542) with main (ef54a25)1

Open in CodSpeed

Footnotes

  1. No successful run was found on main (9cb3b30) during the generation of this report, so ef54a25 was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@coderabbitai

coderabbitai Bot commented Sep 21, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

Understand this PR’s impact

Explore downstream dependencies and potential security impact with Blast Radius.

View blast radius →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 9d180391-8749-44e6-ac99-643bc87deff6

📥 Commits

Reviewing files that changed from the base of the PR and between 886f542 and 8bb0182.

⛔ Files ignored due to path filters (3)
  • capture/output/nuxt-dev-plain-restart.svg is excluded by !**/*.svg
  • capture/output/nuxt-dev-plain-static.svg is excluded by !**/*.svg
  • capture/output/nuxt-dev-plain.svg is excluded by !**/*.svg
📒 Files selected for processing (11)
  • capture/captures.config.ts
  • capture/fixture-data/starter-templates/content.json
  • capture/fixture-data/starter-templates/listing.json
  • capture/fixture-data/starter-templates/minimal.json
  • capture/fixture-data/starter-templates/module.json
  • capture/fixture-data/starter-templates/ui.json
  • capture/fixture-data/starter-templates/v5-nightly.json
  • capture/lib/scrub.ts
  • capture/output/nuxt-dev-plain-restart.txt
  • capture/output/nuxt-dev-plain-static.txt
  • capture/output/nuxt-dev-plain.txt

Included review availability: Your plan provides up to 2 included reviews per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The pull request improves Nuxt CLI test reliability. Lifecycle cleanup retries temporary directory removal up to three times. Error-channel tests add waitForOpened and use it to wait for non-empty editor output before assertions.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 4 files. (9 skipped: 9… Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ❓ Inconclusive The description is related to the test fixture changes, but it is too generic to explain which fixtures were updated or what race condition was fixed. Describe the affected test fixtures and explain that the changes prevent asynchronous cleanup, file creation, or captured-output work from racing the assertions.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the primary change: preventing two test fixtures from racing the work they verify.
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: Docstring Coverage

Explanation

Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 4 files. (9 skipped: 9 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

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.

@danielroe
danielroe disabled auto-merge September 21, 2026 22:36
@danielroe
danielroe enabled auto-merge September 21, 2026 23:21
@danielroe
danielroe added this pull request to the merge queue Sep 21, 2026
Merged via the queue into main with commit c20f347 Sep 21, 2026
21 of 22 checks passed
@danielroe
danielroe deleted the test/fixture-races branch September 21, 2026 23:30
@github-actions github-actions Bot mentioned this pull request Sep 21, 2026
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