-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'development' into remove-survey-banner
- Loading branch information
Showing
44 changed files
with
1,306 additions
and
1,515 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,8 +15,21 @@ jobs: | |
with: | ||
node-version-file: ".nvmrc" | ||
|
||
- name: Set environment for branch | ||
run: | | ||
if [[ $GITHUB_REF_NAME == 'production' ]]; then | ||
echo "BASE_URL=https://drb-qa.nypl.org/" >> "$GITHUB_ENV" | ||
else | ||
echo "BASE_URL=http://local.nypl.org:3000/" >> "$GITHUB_ENV" | ||
fi | ||
- name: Add hosts to /etc/hosts | ||
if: github.ref != 'production' | ||
run: | | ||
sudo echo "127.0.0.1 local.nypl.org" | sudo tee -a /etc/hosts | ||
- name: Install Test Dependencies | ||
run: npm i @cucumber/[email protected] @playwright/test@1.29.1 | ||
run: npm i @playwright/test@1.49.1 | ||
|
||
- name: Install Playwright | ||
run: npx playwright install --with-deps | ||
|
@@ -25,26 +38,17 @@ jobs: | |
run: NODE_ENV=test npm run build | ||
|
||
- name: Start the app | ||
if: github.ref != 'production' | ||
run: | | ||
NODE_ENV=test npm start & | ||
sleep 5 | ||
shell: bash | ||
|
||
- name: Run your tests | ||
run: npm run playwright | ||
|
||
- name: Set the world parameters as an env var | ||
# WORLD_PARAMETERS set here will override anything set in cucumber.json | ||
run: | | ||
echo "WORLD_PARAMETERS={\"headless\": true}" >> $GITHUB_ENV | ||
- name: Run Cucumber tests | ||
run: npm run cucumber -- playwright/features --world-parameters '${{ env.WORLD_PARAMETERS }}' | ||
env: | ||
CATALOG_USERNAME: ${{ secrets.CATALOG_USERNAME }} | ||
CATALOG_USER_PIN: ${{ secrets.CATALOG_USER_PIN }} | ||
CUCUMBER_PUBLISH_TOKEN: ${{ secrets.CUCUMBER_PUBLISH_TOKEN }} | ||
CUCUMBER_PUBLISH_ENABLED: true | ||
|
||
- name: Slack Notification | ||
if: ${{ always() }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.