Skip to content

Use spawn to run CLI tests#5960

Merged
rollup-bot merged 1 commit into
masterfrom
use-spawn-for-cli
May 17, 2025
Merged

Use spawn to run CLI tests#5960
rollup-bot merged 1 commit into
masterfrom
use-spawn-for-cli

Conversation

@lukastaegert

Copy link
Copy Markdown
Member

This ensures that abortOnStderr works

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

List any relevant issue numbers:

Description

The Linux and Windows CLI watch tests take very long because killing the child process does not work when using child_process.exec. It does work for .spawn, though, at least on Linux. This changes most of the tests to use spawn instead, which should also make them slightly faster as they no longer require an in-between process.

@vercel

vercel Bot commented May 17, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
rollup ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 17, 2025 7:20am

@github-actions

github-actions Bot commented May 17, 2025

Copy link
Copy Markdown

Thank you for your contribution! ❤️

You can try out this pull request locally by installing Rollup via

npm install rollup/rollup#use-spawn-for-cli

Notice: Ensure you have installed the latest stable Rust toolchain. If you haven't installed it yet, please see https://www.rust-lang.org/tools/install to learn how to download Rustup and install Rust.

or load it into the REPL:
https://rollup-35g4e49nf-rollup-js.vercel.app/repl/?pr=5960

This ensures that abortOnStderr works
@github-actions

Copy link
Copy Markdown

Performance report

  • BUILD: 7478ms, 748 MB
    • initialize: 0ms, 28.2 MB
    • generate module graph: 2869ms, 562 MB
      • generate ast: 1270ms, 554 MB
    • sort and bind modules: 407ms, 606 MB
    • mark included statements: 4203ms, 748 MB
      • treeshaking pass 1: 2482ms, 745 MB
      • treeshaking pass 2: 482ms (-15ms, -3.0%), 748 MB
      • treeshaking pass 3: 416ms, 749 MB
      • treeshaking pass 4: 409ms, 747 MB
      • treeshaking pass 5: 404ms, 748 MB
  • GENERATE: 765ms, 988 MB
    • initialize render: 0ms, 884 MB
    • generate chunks: 79ms, 893 MB
      • optimize chunks: 0ms, 892 MB
    • render chunks: 669ms, 962 MB
    • transform chunks: 16ms, 988 MB
    • generate bundle: 0ms, 988 MB

@codecov

codecov Bot commented May 17, 2025

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.77%. Comparing base (dd29577) to head (3a53f58).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5960      +/-   ##
==========================================
+ Coverage   98.56%   98.77%   +0.20%     
==========================================
  Files         270      270              
  Lines        8726     8726              
  Branches     1504     1504              
==========================================
+ Hits         8601     8619      +18     
+ Misses         92       73      -19     
- Partials       33       34       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@rollup-bot rollup-bot added this pull request to the merge queue May 17, 2025
Merged via the queue into master with commit 7759f56 May 17, 2025
@rollup-bot rollup-bot deleted the use-spawn-for-cli branch May 17, 2025 11:56
@github-actions

Copy link
Copy Markdown

This PR has been released as part of rollup@4.41.0. You can test it via npm install rollup.

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.

2 participants