chore(tx-builder): remove gnosis-safe.io domain references (#758) #920
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
name: Safe Apps E2E | |
on: | |
pull_request: | |
push: | |
branches: | |
- development | |
- main | |
jobs: | |
e2e: | |
runs-on: ubuntu-latest | |
name: Execute E2E tests | |
steps: | |
- name: Cancel previous runs | |
uses: styfle/[email protected] | |
with: | |
access_token: ${{ github.token }} | |
- name: Checkout web-core | |
uses: actions/checkout@v3 | |
with: | |
repository: safe-global/web-core | |
ref: main | |
path: web-core | |
- name: Yarn install web-core | |
working-directory: web-core | |
run: yarn install | |
- name: Yarn cache web-core modules | |
uses: actions/cache@v3 | |
with: | |
path: 'web-core/**/node_modules' | |
key: web-core-modules-${{ hashFiles('**/yarn.lock') }} | |
- name: Build web-core | |
working-directory: web-core | |
run: yarn build && yarn export | |
env: | |
NEXT_PUBLIC_INFURA_TOKEN: ${{ secrets.CYPRESS_INFURA_TOKEN }} | |
NEXT_PUBLIC_SAFE_APPS_INFURA_TOKEN: ${{ secrets.CYPRESS_INFURA_TOKEN }} | |
NEXT_PUBLIC_TENDERLY_ORG_NAME: ${{ secrets.REACT_APP_TENDERLY_ORG_NAME }} | |
NEXT_PUBLIC_TENDERLY_PROJECT_NAME: ${{ secrets.REACT_APP_TENDERLY_PROJECT_NAME }} | |
NEXT_PUBLIC_TENDERLY_SIMULATE_ENDPOINT_URL: ${{ secrets.REACT_APP_TENDERLY_SIMULATE_ENDPOINT_URL }} | |
NEXT_PUBLIC_CYPRESS_MNEMONIC: ${{ secrets.CYPRESS_MNEMONIC }} | |
- name: Serve web-core | |
working-directory: web-core | |
run: | | |
yarn serve & | |
- name: Set PR Safe Apps base URL | |
run: | | |
echo "SAFE_APPS_BASE_URL=https://pr${{ github.event.number }}--safereactapps.review-react-hr.5afe.dev" >> $GITHUB_ENV | |
if: github.ref != 'refs/heads/development' | |
- name: Set development Safe Apps base URL | |
run: | | |
echo "SAFE_APPS_BASE_URL=https://safe-apps.dev.5afe.dev" >> $GITHUB_ENV | |
if: github.ref == 'refs/heads/development' | |
- name: Set main Safe Apps base URL | |
run: | | |
echo "SAFE_APPS_BASE_URL=https://apps-portal.safe.global" >> $GITHUB_ENV | |
if: ${{ github.ref == 'refs/heads/main' || github.event.schedule == '0 9 * * 1-5' }} | |
- name: Checkout safe-react-apps | |
uses: actions/checkout@v3 | |
with: | |
repository: safe-global/safe-react-apps | |
path: apps | |
- name: Execute E2E tests | |
uses: cypress-io/github-action@v5 | |
with: | |
browser: chrome | |
record: true | |
spec: cypress/e2e/drain-account/drain.spec.cy.js,cypress/e2e/tx-builder/tx-builder.spec.cy.js | |
wait-on: 'http://localhost:8080' | |
working-directory: apps | |
env: | |
CI: 'true' | |
CYPRESS_WEB_BASE_URL: 'http://localhost:8080' | |
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} | |
CYPRESS_CHAIN_ID: '5' | |
CYPRESS_NETWORK_PREFIX: 'gor' | |
CYPRESS_TESTING_SAFE_ADDRESS: '0x168ca275d1103cb0a30980813140053c7566932F' | |
CYPRESS_CLIENT_GATEWAY_BASE_URL: 'https://safe-client.safe.global' | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
CYPRESS_DRAIN_SAFE_URL: ${{ env.SAFE_APPS_BASE_URL }}/drain-safe | |
CYPRESS_TX_BUILDER_URL: ${{ env.SAFE_APPS_BASE_URL }}/tx-builder | |
continue-on-error: false |