From 2a1d325d085f645c0beb5ac9eaa3b236afe44385 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C4=B1z=C4=B1r=20Sefa=20=C4=B0rken?= Date: Thu, 12 Sep 2024 17:13:28 +0300 Subject: [PATCH] fixup! feat(e2e): enable blockfrst e2e test in CI --- .../continuous-integration-e2e-blockfrost.yaml | 4 ++-- .github/workflows/continuous-integration-e2e.yaml | 11 +++++++++-- packages/e2e/delete | 0 packages/e2e/docker-compose.yml | 1 + packages/e2e/package.json | 3 ++- 5 files changed, 14 insertions(+), 5 deletions(-) create mode 100644 packages/e2e/delete diff --git a/.github/workflows/continuous-integration-e2e-blockfrost.yaml b/.github/workflows/continuous-integration-e2e-blockfrost.yaml index 9a1dcd91954..7d568e1e17b 100644 --- a/.github/workflows/continuous-integration-e2e-blockfrost.yaml +++ b/.github/workflows/continuous-integration-e2e-blockfrost.yaml @@ -27,7 +27,7 @@ env: TEST_CLIENT_STAKE_POOL_PROVIDER: 'http' TEST_CLIENT_STAKE_POOL_PROVIDER_PARAMS: '{"baseUrl":"http://localhost:4000/"}' WS_PROVIDER_URL: 'http://localhost:4100/ws' - # enable Blockfrost backed providers + # enable Blockfrost backed providers, the rest will use defaults ASSET_PROVIDER: 'blockfrost' UTXO_PROVIDER: 'blockfrost' CHAIN_HISTORY_PROVIDER: 'blockfrost' @@ -70,7 +70,7 @@ jobs: - name: 🌐 Setup local test network working-directory: packages/e2e run: | - yarn local-network:up -d + yarn local-network:blockfrost:up -d env: CARDANO_NODE_CHAINDB_LOG_LEVEL: 'Warning' CARDANO_NODE_LOG_LEVEL: 'Warning' diff --git a/.github/workflows/continuous-integration-e2e.yaml b/.github/workflows/continuous-integration-e2e.yaml index aa3d1790124..7d568e1e17b 100644 --- a/.github/workflows/continuous-integration-e2e.yaml +++ b/.github/workflows/continuous-integration-e2e.yaml @@ -1,4 +1,4 @@ -name: Continuous Integration - E2E +name: Continuous Integration - E2E (Blockfrost Providers) env: TL_DEPTH: ${{ github.event.pull_request.head.repo.fork && '0' || fromJson(vars.TL_DEPTH) }} @@ -27,6 +27,13 @@ env: TEST_CLIENT_STAKE_POOL_PROVIDER: 'http' TEST_CLIENT_STAKE_POOL_PROVIDER_PARAMS: '{"baseUrl":"http://localhost:4000/"}' WS_PROVIDER_URL: 'http://localhost:4100/ws' + # enable Blockfrost backed providers, the rest will use defaults + ASSET_PROVIDER: 'blockfrost' + UTXO_PROVIDER: 'blockfrost' + CHAIN_HISTORY_PROVIDER: 'blockfrost' + REWARDS_PROVIDER: 'blockfrost' + NETWORK_INFO_PROVIDER: 'blockfrost' + TX_SUBMIT_PROVIDER: 'blockfrost' on: pull_request: @@ -63,7 +70,7 @@ jobs: - name: 🌐 Setup local test network working-directory: packages/e2e run: | - yarn local-network:up -d + yarn local-network:blockfrost:up -d env: CARDANO_NODE_CHAINDB_LOG_LEVEL: 'Warning' CARDANO_NODE_LOG_LEVEL: 'Warning' diff --git a/packages/e2e/delete b/packages/e2e/delete new file mode 100644 index 00000000000..e69de29bb2d diff --git a/packages/e2e/docker-compose.yml b/packages/e2e/docker-compose.yml index 76c21b8c0a2..f4ca9a127d3 100644 --- a/packages/e2e/docker-compose.yml +++ b/packages/e2e/docker-compose.yml @@ -15,6 +15,7 @@ services: NODE_ENV: local-network volumes: - ./local-network/config/network/blockfrost-ryo:/app/config + profiles: [blockfrost-ryo] local-testnet: <<: *logging diff --git a/packages/e2e/package.json b/packages/e2e/package.json index fec1b37f565..c860e3881a7 100644 --- a/packages/e2e/package.json +++ b/packages/e2e/package.json @@ -46,8 +46,9 @@ "test:web-extension:watch": "run-s test:web-extension:build test:web-extension:watch:bg", "test:web-extension:watch:bg": "run-p test:web-extension:watch:build test:web-extension:watch:run", "test:ws": "jest -c jest.config.js --forceExit --selectProjects ws-server --runInBand --verbose", - "local-network:common": "DISABLE_DB_CACHE=${DISABLE_DB_CACHE:-true} SUBMIT_API_ARGS='--testnet-magic 888' USE_BLOCKFROST=false __FIX_UMASK__=$(chmod -R a+r ../../compose/placeholder-secrets) docker compose --env-file ../cardano-services/environments/.env.local -p local-network-e2e -f docker-compose.yml -f ../../compose/common.yml -f ../../compose/$(uname -m).yml $FILES up", + "local-network:common": "DISABLE_DB_CACHE=${DISABLE_DB_CACHE:-true} SUBMIT_API_ARGS='--testnet-magic 888' USE_BLOCKFROST=false __FIX_UMASK__=$(chmod -R a+r ../../compose/placeholder-secrets) docker compose --env-file ../cardano-services/environments/.env.local -p local-network-e2e -f docker-compose.yml -f ../../compose/common.yml -f ../../compose/$(uname -m).yml $FILES --profile ${DOCKER_COMPOSE_PROFILE:-none} up", "local-network:up": "FILES='' yarn local-network:common", + "local-network:blockfrost:up": "FILES='' DOCKER_COMPOSE_PROFILE='blockfrost-ryo' yarn local-network:common", "local-network:single:up": "FILES='' yarn local-network:common cardano-node file-server local-testnet ogmios postgres", "local-network:profile:up": "FILES='-f ../../compose/pg-agent.yml' yarn local-network:common", "local-network:down": "docker compose -p local-network-e2e -f docker-compose.yml -f ../../compose/common.yml -f ../../compose/pg-agent.yml down -v --remove-orphans",