set dist as the path

This commit is contained in:
Murat Ozcan 2022-05-04 10:37:11 -05:00
parent 9466366dda
commit f770ac60d5
4 changed files with 26 additions and 20 deletions

View File

@ -27,26 +27,29 @@ jobs:
# # pass GitHub token to allow accurately detecting a build vs a re-run build # # pass GitHub token to allow accurately detecting a build vs a re-run build
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#############################################################################################################################
# Version 2: install in one job, parallelize the e2e jobs # Version 2: install in one job, parallelize the e2e jobs
- name: Cypress install - name: Cypress install
uses: cypress-io/github-action@v2 uses: cypress-io/github-action@v2
with: with:
runTests: false runTests: false
# probably Vercel relevant. No idea why we have to build anything, so far # probably Vercel relevant. No idea why we have to build anything
# In version 1, I did not have to build anything to get things to work in CI # In version 1, I did not have to build anything to get things to work in CI
# - run: yarn build # here, without the build job generating an artifact, the test jobs do not really get items related to our store
# env: - run: yarn build
# COMMERCE_PROVIDER: ${{ secrets.COMMERCE_PROVIDER }} env:
# NEXT_PUBLIC_SHOPIFY_STORE_DOMAIN: ${{ secrets.NEXT_PUBLIC_SHOPIFY_STORE_DOMAIN }} COMMERCE_PROVIDER: ${{ secrets.COMMERCE_PROVIDER }}
# NEXT_PUBLIC_SHOPIFY_STOREFRONT_ACCESS_TOKEN: ${{ secrets.NEXT_PUBLIC_SHOPIFY_STOREFRONT_ACCESS_TOKEN }} NEXT_PUBLIC_SHOPIFY_STORE_DOMAIN: ${{ secrets.NEXT_PUBLIC_SHOPIFY_STORE_DOMAIN }}
NEXT_PUBLIC_SHOPIFY_STOREFRONT_ACCESS_TOKEN: ${{ secrets.NEXT_PUBLIC_SHOPIFY_STOREFRONT_ACCESS_TOKEN }}
# - name: Save build folder - name: Save build folder
# uses: actions/upload-artifact@v2 uses: actions/upload-artifact@v2
# with: with:
# name: build name: build
# if-no-files-found: error if-no-files-found: error
# path: build path: dist
ui-chrome-tests: ui-chrome-tests:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -60,11 +63,11 @@ jobs:
uses: actions/checkout@v2 uses: actions/checkout@v2
# must be Vercel relevant. No idea why we have to build anything # must be Vercel relevant. No idea why we have to build anything
# - name: Download the build folders - name: Download the build folders
# uses: actions/download-artifact@v2 uses: actions/download-artifact@v2
# with: with:
# name: build name: build
# path: build path: dist
- name: 'Chrome E2E Tests' - name: 'Chrome E2E Tests'
uses: cypress-io/github-action@v2 uses: cypress-io/github-action@v2

View File

@ -17,7 +17,6 @@
}, },
"devDependencies": { "devDependencies": {
"cypress": "^9.6.0", "cypress": "^9.6.0",
"dotenv": "^16.0.0",
"husky": "^7.0.4", "husky": "^7.0.4",
"prettier": "^2.5.1", "prettier": "^2.5.1",
"turbo": "^1.1.2" "turbo": "^1.1.2"

View File

@ -425,3 +425,7 @@ In the parallelization section, the jobs with `yarn build` and `save build folde
__________ __________
Unsure about any of the `build` instructions. The yml at the end of Part 5 does not work as advertised. The build job does not generate a build path and errors out. We should just be able to install and cache to perpetual jobs in an easy way without having to crud the build folder.
https://github.com/muratkeremozcan/nextjs-cypress/runs/6292547384?check_suite_focus=true

View File

@ -23,8 +23,8 @@
"@components/*": ["components/*"], "@components/*": ["components/*"],
"@commerce": ["../packages/commerce/src"], "@commerce": ["../packages/commerce/src"],
"@commerce/*": ["../packages/commerce/src/*"], "@commerce/*": ["../packages/commerce/src/*"],
"@framework": ["../packages/shopify/src"], "@framework": ["../packages/local/src"],
"@framework/*": ["../packages/shopify/src/*"] "@framework/*": ["../packages/local/src/*"]
} }
}, },
"include": ["next-env.d.ts", "**/*.d.ts", "**/*.ts", "**/*.tsx", "**/*.js"], "include": ["next-env.d.ts", "**/*.d.ts", "**/*.ts", "**/*.tsx", "**/*.js"],