Skip to content

Add smoke test for npm maintainer encoding (PR #14638)#455

Open
v-HaripriyaC wants to merge 3 commits intomainfrom
chp/npmbunPR-14638
Open

Add smoke test for npm maintainer encoding (PR #14638)#455
v-HaripriyaC wants to merge 3 commits intomainfrom
chp/npmbunPR-14638

Conversation

@v-HaripriyaC
Copy link
Copy Markdown

@v-HaripriyaC v-HaripriyaC commented Apr 15, 2026

What are you trying to accomplish?

Add smoke test coverage for dependabot-core#14638, which fixes broken Markdown links in the Maintainer changes section of Dependabot PR bodies when an npm releaser name contains spaces or other URL-unsafe characters (e.g., "GitHub Actions"). Addresses dependabot-core#14595.

The test validates end-to-end that:

  • npm_and_yarn can analyse a package with a space-containing npm maintainer name.
  • The generated PR body contains a properly percent-encoded link (https://www.npmjs.com/~GitHub%20Actions) rather than the broken unencoded form.

Anything you want to highlight for special attention from reviewers?

  • Dependency choice: npm-package-json-lint@9.0.0 is used specifically because the npm registry fixture in dependabot-core#14638 records version 10.0.0 as being published by "GitHub Actions" (with a space), making it the minimal reproducible case.
  • Fixtures: npm/maintainer-spaces/package.json and package-lock.json pin the dependency to 9.0.0 so Dependabot proposes the 9.0.0 → 10.0.0 update and reaches the maintainer encoding path.
  • The smoke test YAML (tests/smoke-npm-maintainer-spaces.yaml) will need to be regenerated with the final merged commit SHA from dependabot-core#14638 before this PR is ready to merge.
  • Currently the test output contains a job_repo_not_found record because the commit SHA is a placeholder; this will be replaced with the real expected output after regeneration.

How will you know you've accomplished your goal?

  • Smoke test regenerates cleanly against the merged dependabot-core#14638 commit.
  • The regenerated output contains a create_pull_request event whose PR body includes https://www.npmjs.com/~GitHub%20Actions (percent-encoded).
  • All existing smoke tests continue to pass.

Checklist

  • I have run the complete test suite to ensure all tests and linters pass.
  • I have thoroughly tested my code changes to ensure they work as expected, including adding additional tests for new functionality.
  • I have written clear and descriptive commit messages.
  • I have provided a detailed description of the changes in the pull request, including the problem it addresses, how it fixes the problem, and any relevant details about the implementation.
  • I have ensured that the code is well-documented and easy to understand.

@v-HaripriyaC v-HaripriyaC requested a review from a team as a code owner April 15, 2026 17:03
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