Prod Mainnet tests #2058
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
# Prod Mainnet tests | |
name: Prod Mainnet tests | |
on: | |
schedule: | |
- cron: '0 8 * * *' # everyday at 8am | |
- cron: '0 22 * * *' # everyday at 10pm | |
env: | |
AMPLITUDE_API_KEY_DEV: ${{ secrets.VUE_APP_AMPLITUDE_API_KEY_DEV }} | |
AMPLITUDE_API_KEY_PROD: ${{ secrets.VUE_APP_AMPLITUDE_API_KEY }} | |
TERRA_MAINNET_URL: ${{ secrets.VUE_APP_TERRA_MAINNET_URL }} | |
AVALANCHE_MAINNET_NODE: ${{ secrets.VUE_APP_AVALANCHE_MAINNET_NODE }} | |
AVALANCHE_TESTNET_NODE: ${{ secrets.VUE_APP_AVALANCHE_TESTNET_NODE }} | |
NEAR_MAINNET_URL: ${{ secrets.VUE_APP_NEAR_MAINNET_URL }} | |
SEED_WORDS: ${{ secrets.TEST_NET_SEED_WORDS }} | |
TWENTY_FOUR_SEEDS: ${{ secrets.TWENTY_FOUR_SEEDS }} | |
TEST_WALLET_PASSWORD: ${{ secrets.TEST_WALLET_PASSWORD }} | |
# Transak details | |
TRANSAK_WIDGET_URL_PROD: ${{ secrets.TRANSAK_WIDGET_URL_PROD }} | |
TRANSAK_API_KEY_PROD: ${{ secrets.TRANSAK_API_KEY_PROD }} | |
TRANSAK_DEFAULT_FIAT_CURRENCY: ${{ secrets.TRANSAK_DEFAULT_FIAT_CURRENCY }} | |
# Onramper details | |
ONRAMPER_WIDGET_URL: ${{ secrets.ONRAMPER_WIDGET_URL }} | |
ONRAMPER_API_KEY: ${{ secrets.ONRAMPER_API_KEY }} | |
jobs: | |
regressiontest_Prod_mainnet: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- uses: actions/[email protected] | |
env: | |
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: 'true' | |
with: | |
node-version: '14' | |
# Create screenshots directory | |
- run: mkdir screenshots | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "::set-output name=dir::$(yarn config get cacheFolder)" | |
- name: Restore yarn cache | |
uses: actions/cache@v3 | |
id: yarn-cache | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }} | |
restore-keys: | | |
yarn-cache-folder- | |
# Create wallet with Dev Prod configuration | |
- name: Set production agents | |
run: | | |
export NODE_OPTIONS="--max-old-space-size=5120" | |
echo VUE_APP_TERRA_MAINNET_URL =$TERRA_MAINNET_URL >> .env | |
echo VUE_APP_AVALANCHE_MAINNET_NODE =$AVALANCHE_MAINNET_NODE >> .env | |
echo VUE_APP_AVALANCHE_TESTNET_NODE =$AVALANCHE_TESTNET_NODE >> .env | |
echo VUE_APP_NEAR_MAINNET_URL =$NEAR_MAINNET_URL >> .env | |
echo VUE_APP_AMPLITUDE_API_KEY =$AMPLITUDE_API_KEY_PROD >> .env | |
echo VUE_APP_TRANSAK_WIDGET_URL =$TRANSAK_WIDGET_URL_PROD >> .env | |
echo VUE_APP_TRANSAK_API_KEY =$TRANSAK_API_KEY_PROD >> .env | |
echo VUE_APP_TRANSAK_DEFAULT_FIAT_CURRENCY =$TRANSAK_DEFAULT_FIAT_CURRENCY >> .env | |
echo VUE_APP_ONRAMPER_WIDGET_URL =$ONRAMPER_WIDGET_URL >> .env | |
echo VUE_APP_ONRAMPER_API_KEY =$ONRAMPER_API_KEY >> .env | |
yarn install | |
yarn lint | |
yarn build | |
- name: Regression tests against (Prod) Mainnet | |
uses: beemi/[email protected] | |
env: | |
CI: 'true' | |
DISPLAY: :99 | |
with: | |
args: yarn test-full-regression # Run tests against Prod mainnet | |
- name: Save Screenshots | |
uses: actions/[email protected] | |
if: always() | |
with: | |
name: screenshots | |
path: screenshots | |
if-no-files-found: ignore |