Skip to content

Commit

Permalink
Adds an e2e test for when using PnP
Browse files Browse the repository at this point in the history
  • Loading branch information
Maël Nison committed Sep 28, 2018
1 parent 63152ef commit 6eb3f33
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Expand Up @@ -9,7 +9,7 @@ cache:
directories:
- .npm
before_install:
- curl -o- -L https://yarnpkg.com/install.sh | bash
- curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --nightly
- export PATH="$HOME/.yarn/bin:$PATH"
install: true
script:
Expand Down
2 changes: 1 addition & 1 deletion appveyor.yml
Expand Up @@ -36,7 +36,7 @@ platform:
install:
- ps: Install-Product node $env:nodejs_version $env:platform
- ps: |
(New-Object Net.WebClient).DownloadFile("https://yarnpkg.com/latest.msi", "$env:temp\yarn.msi")
(New-Object Net.WebClient).DownloadFile("https://nightly.yarnpkg.com/latest.msi", "$env:temp\yarn.msi")
cmd /c start /wait msiexec.exe /i $env:temp\yarn.msi /quiet /qn /norestart
build: off
Expand Down
12 changes: 12 additions & 0 deletions tasks/e2e-installs.sh
Expand Up @@ -229,5 +229,17 @@ npx create-react-app test-app-nested-paths-t3/aa/bb/cc/dd
cd test-app-nested-paths-t3/aa/bb/cc/dd
yarn start --smoke-test

# ******************************************************************************
# Test when PnP is enabled
# ******************************************************************************
cd "$temp_app_path"
echo $OSTYPE
YARN_PLUGNPLAY_OVERRIDE=1 npx create-react-app test-app-pnp
cd test-app-pnp
! exists node_modules
exists .pnp.js
yarn start --smoke-test
yarn build

# Cleanup
cleanup

0 comments on commit 6eb3f33

Please sign in to comment.