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: remove dependency on realpath-native #9952

Merged
merged 7 commits into from
May 2, 2020

Conversation

SimenB
Copy link
Member

@SimenB SimenB commented May 2, 2020

Summary

We don't need it anymore as node 10 has realpathSync.native

Test plan

Green CI


try {
cwd = fs.realpathSync.native(cwd);
} catch (error) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

can we use tryRealpath instead?

Copy link
Collaborator

Choose a reason for hiding this comment

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

or create a second helper just for jest-cli, since the other one is in jest-config

@@ -29,6 +29,18 @@ import type {
import shouldInstrument from './shouldInstrument';
import handlePotentialSyntaxError from './enhanceUnexpectedTokenMessage';

function tryRealpath(path: Config.Path): Config.Path {
Copy link
Collaborator

Choose a reason for hiding this comment

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

lots of tryRealPath here and there 😅

@SimenB
Copy link
Member Author

SimenB commented May 2, 2020

Yeah... Can stick it in jest-util 😀 I'm heading outside to catch some rays now - if you've got some time, landing this somehow that'd be lovely

@thymikee
Copy link
Collaborator

thymikee commented May 2, 2020

@SimenB on it

CHANGELOG.md Outdated
@@ -15,6 +15,7 @@
- `[*]` [**BREAKING**] TypeScript definitions requires a minimum of TypeScript v3.8 ([#9823](https://github.com/facebook/jest/pull/9823))
- `[*]` [**BREAKING**] Drop support for Node 8 ([#9423](https://github.com/facebook/jest/pull/9423))
- `[*]` Upgrade to chalk@4 ([#9752](https://github.com/facebook/jest/pull/9752))
- `[*]` Remove usage of `realpath-native`
Copy link
Member Author

Choose a reason for hiding this comment

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

Should link the pr

@SimenB SimenB merged commit 1cc205c into jestjs:master May 2, 2020
@SimenB SimenB deleted the drop-realpath-native branch May 2, 2020 15:58
@SimenB
Copy link
Member Author

SimenB commented May 2, 2020

Thanks @thymikee!

jeysal added a commit to jeysal/jest that referenced this pull request May 2, 2020
…hile-running

* upstream/master: (331 commits)
  chore: update ts-eslint (jestjs#9953)
  Updated config docs with default transform value (jestjs#8583)
  Update jest-phabricator documentation (jestjs#8662)
  chore: remove dependency on `realpath-native` (jestjs#9952)
  chore: bump dated dependencies (jestjs#9951)
  chore: another try at fixing test-utils dependency
  chore: update lockfile due to beta release
  chore: move changelog entry and fix tets utils dependency
  Fix time duration formatting as per SI (jestjs#9765)
  v26.0.0-alpha.0
  chore: run some jsdom tests in leak check (jestjs#9938)
  chore: upgrade chalk to v4 (jestjs#9752)
  feat: upgrade to JSDOM 16 (jestjs#9606)
  chore: remove checks for compileFunction (jestjs#9949)
  chore: drop node 8 support  (jestjs#9423)
  Remove leftover `providesModuleNodeModules` (jestjs#9948)
  [BREAKING] Pojer -> Nakazawa
  chore: revert lockfile changes from 2b32fe6
  chore: move changelog entry and fix lint
  Remove `providesModuleNodeModules` from Jest. (jestjs#9583)
  ...
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 11, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants