diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 771fdeaed0..bad56c7926 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -18,12 +18,13 @@ jobs: with: node-version: 16.x cache: 'yarn' + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn install --immutable - run: yarn compile - run: yarn devchain & env: MAINNET_RPC_URL: https://eth-mainnet.alchemyapi.io/v2/${{ secrets.ALCHEMY_MAINNET_KEY }} - CI: true - run: yarn deploy:run --network localhost env: SKIP_PROMPT: 1 @@ -38,6 +39,8 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn lint @@ -51,6 +54,8 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:plugins - name: 'Cache hardhat network fork' @@ -66,7 +71,6 @@ jobs: NODE_OPTIONS: '--max-old-space-size=4096' TS_NODE_SKIP_IGNORE: true MAINNET_RPC_URL: https://eth-mainnet.alchemyapi.io/v2/${{ secrets.ALCHEMY_MAINNET_KEY }} - CI: true p0-tests: name: 'P0 tests' @@ -78,11 +82,12 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:p0 env: NODE_OPTIONS: '--max-old-space-size=4096' - CI: true p1-tests: name: 'P1 Tests' @@ -94,11 +99,12 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:p1 env: NODE_OPTIONS: '--max-old-space-size=4096' - CI: true scenario-tests: name: 'Scenario Tests' @@ -110,11 +116,12 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:scenario env: NODE_OPTIONS: '--max-old-space-size=8192' - CI: true extreme-tests: name: 'Extreme Tests' @@ -126,6 +133,8 @@ jobs: node-version: 16.x cache: 'yarn' - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:extreme - name: 'Cache hardhat network fork' @@ -141,7 +150,6 @@ jobs: NODE_OPTIONS: '--max-old-space-size=4096' TS_NODE_SKIP_IGNORE: true MAINNET_RPC_URL: https://eth-mainnet.alchemyapi.io/v2/${{ secrets.ALCHEMY_MAINNET_KEY }} - CI: true integration-tests: name: 'Integration Tests' @@ -163,10 +171,11 @@ jobs: hardhat-network-fork-${{ runner.os }}- hardhat-network-fork- - run: yarn install --immutable + - run: curl https://raw.githubusercontent.com/Tenderly/tenderly-cli/master/scripts/install-linux.sh | sudo sh + - run: tenderly login --authentication-method access-key --access-key ${{ secrets.TENDERLY_ACCESS_KEY }} --force - run: yarn compile - run: yarn test:integration env: NODE_OPTIONS: '--max-old-space-size=4096' TS_NODE_SKIP_IGNORE: true MAINNET_RPC_URL: https://eth-mainnet.alchemyapi.io/v2/${{ secrets.ALCHEMY_MAINNET_KEY }} - CI: true diff --git a/README.md b/README.md index 9f10688371..ae48bf253d 100644 --- a/README.md +++ b/README.md @@ -154,6 +154,8 @@ If you would like to contribute, you'll need to configure a secret in your fork Usage: `https://eth-mainnet.alchemyapi.io/v2/${{ secrets.ALCHEMY_MAINNET_KEY }}` +To get setup with tenderly, install the [tenderly cli](https://github.com/Tenderly/tenderly-cli). and login with `tenderly login --authentication-method access-key --access-key {your_access_key} --force`. + ## External Documentation [Video overview](https://youtu.be/341MhkOWsJE) diff --git a/utils/env.ts b/utils/env.ts index 0edff72e06..540a910714 100644 --- a/utils/env.ts +++ b/utils/env.ts @@ -21,7 +21,6 @@ type IEnvVars = | 'SUBGRAPH_URL' | 'TENDERLY_RPC_URL' | 'SKIP_PROMPT' - | 'CI' export function useEnv(key: IEnvVars | IEnvVars[], _default = ''): string { if (typeof key === 'string') {