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

Simplify workaround that overrides Jest clone folder on Azure Pipelines #8413

Merged
merged 1 commit into from May 2, 2019

Conversation

willsmythe
Copy link
Contributor

@willsmythe willsmythe commented May 2, 2019

Summary

This simplifies the Azure Pipelines-specific workaround that overrides the folder Jest gets cloned into during a CI build. See azure-pipelines-steps.yml (line 22).

Why this change? There is now a property on the "checkout" step that makes it easy to set the target directory of "git clone". This avoids the need for a separate step that copies the source to a different folder. This also simplifies the YAML.

Here's why this workaround was (and still is) necessary:

By default, Azure Pipelines clones to an "s" directory, which causes some Jest tests to fail due to the assumption by Jest that it is being run from a "jest" directory (see packages/jest-message-util/src/index.js PATH_JEST_PACKAGES for more details).

Test plan

Since this is an Azure Pipelines specific change, there is no impact to the functionality of Jest or existing tests. Just need to ensure the "Git checkout" step shows cloning into a "jest" folder and all tests pass correctly on Windows, Linux, and macOS.

@codecov-io
Copy link

Codecov Report

Merging #8413 into master will increase coverage by 0.02%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #8413      +/-   ##
==========================================
+ Coverage   62.32%   62.34%   +0.02%     
==========================================
  Files         266      266              
  Lines       10733    10734       +1     
  Branches     2615     2610       -5     
==========================================
+ Hits         6689     6692       +3     
+ Misses       3461     3460       -1     
+ Partials      583      582       -1
Impacted Files Coverage Δ
packages/jest-resolve/src/defaultResolver.ts 64.06% <0%> (-4.06%) ⬇️
packages/jest-config/src/index.ts 12.5% <0%> (+0.55%) ⬆️
packages/jest-snapshot/src/utils.ts 93.33% <0%> (+0.9%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1c5d830...5fae6c1. Read the comment docs.

Copy link
Contributor

@jeysal jeysal left a comment

Choose a reason for hiding this comment

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

Nice!

@jeysal jeysal merged commit b870306 into jestjs:master May 2, 2019
@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.

None yet

4 participants