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

Fix tightly-coupled dependency on Stylelint's internal module lib/utils/getOsEol #66

Merged
merged 4 commits into from Jul 26, 2023

Conversation

ybiquitous
Copy link
Member

Which issue, if any, is this issue related to?

Ref stylelint/stylelint#7099

Is there anything in the PR that needs further explanation?

This change aims to make changes easier by removing the dependency on an internal module.

Summary:

  • Change the os.EOL property by the before/all hooks instead of mocking.
  • Add a file for setupFilesAfterEnv.
  • Delay requiring stylelint in getTestRule().

See also:

This change aims to make changes easier by removing the dependency on an internal module.

Summary:
- Change the `os.EOL` property by the before/all hooks instead of mocking.
- Add a file for `setupFilesAfterEnv`.
- Delay requiring `stylelint` in `getTestRule()`.

See also:
- https://github.com/stylelint/stylelint/blob/0dbed54626e87786c2ef2e4ccd4c27d04c8a6918/lib/utils/getOsEol.js
- https://jestjs.io/docs/configuration/#setupfilesafterenv-array
CHANGELOG.md Outdated Show resolved Hide resolved
@ybiquitous ybiquitous changed the title Remove dependency on Stylelint's internal module lib/utils/getOsEol Fix tightly-coupled dependency on Stylelint's internal module lib/utils/getOsEol Jul 26, 2023
…jest-setup-after-env.js`"

This reverts commit ebe4650.
@ybiquitous ybiquitous requested a review from jeddy3 July 26, 2023 08:36
Copy link
Member

@jeddy3 jeddy3 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@ybiquitous
Copy link
Member Author

Thanks for the review. I'll release 6.1.1 soon.

@ybiquitous ybiquitous merged commit 61ab750 into main Jul 26, 2023
6 checks passed
@ybiquitous ybiquitous deleted the getOsEol-not-needed branch July 26, 2023 13:58
@ybiquitous
Copy link
Member Author

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.

None yet

2 participants