Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: transform noisy files in e2e migration test #1146

Merged
merged 8 commits into from
Dec 30, 2023

Conversation

JoshuaKGoldberg
Copy link
Owner

@JoshuaKGoldberg JoshuaKGoldberg commented Dec 30, 2023

PR Checklist

Overview

In the migration script, after running with --mode migrate but before running test assertions, modifies a couple of files on disk:

  1. .all-contributorsrc: Formats with JSON.stringify(..., null, 2) as it seems All Contributors isn't able to use Prettier for it
  2. .github/DEVELOPMENT.md: Adds back in the ## The Setup Scripts heading, as it's not part of the default template

Also wraps the tests in describe and standardizes naming just a bit. I'm very nitpicky.

Copy link

codecov bot commented Dec 30, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (8d48fee) 94.27% compared to head (cb455d9) 94.27%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1146   +/-   ##
=======================================
  Coverage   94.27%   94.27%           
=======================================
  Files          97       97           
  Lines        5627     5627           
  Branches      455      455           
=======================================
  Hits         5305     5305           
  Misses        321      321           
  Partials        1        1           
Flag Coverage Δ
create 70.22% <ø> (ø)
initialize 42.15% <ø> (ø)
migrate 69.60% <ø> (ø)
unit 72.31% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

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

test.each([...filesExpectedToBeChanged])("verify %s", async (file) => {
const { stdout } = await execaCommand(`git diff HEAD -- ${file}`);
expect(stdout.split("\n").slice(2).join("\n")).toMatchSnapshot();
// All Contributors seems to not be using Prettier to format files...
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 I wonder if it's that this repo's prettier config has plugins that need to be installed!

@JoshuaKGoldberg JoshuaKGoldberg merged commit b12dcc1 into main Dec 30, 2023
@JoshuaKGoldberg JoshuaKGoldberg deleted the e2e-migrate-file-transforms branch December 30, 2023 11:08
Copy link

🎉 This is included in version v1.50.2 🎉

The release is available on:

Cheers! 📦🚀

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.

🛠 Tooling: Filter out noisy areas from end-to-end migration test snapshots
1 participant