Skip to content

Scripts: Avoid tests getting published to npm#79204

Merged
manzoorwanijk merged 2 commits into
trunkfrom
update/scripts/skip-test-for-npm
Jun 15, 2026
Merged

Scripts: Avoid tests getting published to npm#79204
manzoorwanijk merged 2 commits into
trunkfrom
update/scripts/skip-test-for-npm

Conversation

@manzoorwanijk

Copy link
Copy Markdown
Member

Follow up of #79095 (comment)

What?

Currently, the script package publishes test files to npm, which it ideally shouldn't.

Why?

The test files are not meant for npm.

How?

  • Add a negation for test directory to skip it for publishing
  • Move rimraf to dev deps

Testing Instructions

  • cd packages/scripts && npm pack
  • Unpack the tarbal
  • Verify that the test directory is not included.

Testing Instructions for Keyboard

Screenshots or screencast

Before After

Use of AI Tools

@manzoorwanijk manzoorwanijk requested a review from aduth June 15, 2026 17:42
@manzoorwanijk manzoorwanijk self-assigned this Jun 15, 2026
@manzoorwanijk manzoorwanijk requested a review from gziolo as a code owner June 15, 2026 17:42
@manzoorwanijk manzoorwanijk added the [Type] Code Quality Issues or PRs that relate to code quality label Jun 15, 2026
@manzoorwanijk manzoorwanijk added the [Tool] WP Scripts /packages/scripts label Jun 15, 2026
@github-actions

Copy link
Copy Markdown

Size Change: 0 B

Total Size: 8.58 MB

compressed-size-action

@github-actions

Copy link
Copy Markdown

Flaky tests detected in 8d9c15a.
Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.

🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/27564964996
📝 Reported issues:

Comment thread packages/scripts/package.json Outdated
@github-actions

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: manzoorwanijk <manzoorwanijk@git.wordpress.org>
Co-authored-by: aduth <aduth@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Co-authored-by: Andrew Duthie <1779930+aduth@users.noreply.github.com>
@manzoorwanijk manzoorwanijk enabled auto-merge (squash) June 15, 2026 18:44
@manzoorwanijk manzoorwanijk merged commit fcaa78c into trunk Jun 15, 2026
41 of 43 checks passed
@manzoorwanijk manzoorwanijk deleted the update/scripts/skip-test-for-npm branch June 15, 2026 19:14
@github-actions github-actions Bot added this to the Gutenberg 23.5 milestone Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Tool] WP Scripts /packages/scripts [Type] Code Quality Issues or PRs that relate to code quality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants