Tests Nightly #429
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: Tests Nightly | |
on: | |
schedule: | |
- cron: '30 5 * * *' | |
jobs: | |
unit-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- name: Install dependencies | |
run: | | |
yarn | |
- name: Run linters | |
run: yarn lint | |
- name: Start ganache | |
run: yarn ganache --port 18545 --chain.chainId 8998 & | |
- uses: actions/checkout@v3 | |
with: | |
repository: nevermined-io/contracts | |
ref: 'main' | |
path: contracts | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
- name: Deploy contracts | |
run: | | |
cd contracts | |
yarn | |
export TESTNET=true | |
export NETWORK=external | |
./scripts/build-circuit.sh | |
yarn deploy | |
mv artifacts .. | |
mv circuits .. | |
cd .. | |
rm -rf contracts | |
- name: Run unit tests | |
env: | |
ETH_PORT: 18545 | |
run: | | |
yarn run test:cover | |
subgraph-integration: | |
runs-on: ubuntu-latest | |
if: ${{ false }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- uses: nevermined-io/[email protected] | |
with: | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
opengsn: 'true' | |
estuary: 'true' | |
compute: 'true' | |
contracts-version: 'v3.2.1' | |
node-version: 'v1.2.16' | |
- name: Install dependencies | |
run: | | |
yarn | |
- name: Check artifacts | |
run: | | |
nvm-tools copy-artifacts ./artifacts | |
ls -l artifacts | |
- name: Run subgraph integration tests | |
env: | |
SEED_WORDS: ${{ secrets.seedWords }} | |
INFURA_TOKEN: ${{ secrets.INFURA_TOKEN }} | |
run: | | |
export GRAPH_DELAY=true | |
npm run integration:subgraph | |
- name: Run compute integration tests | |
env: | |
SEED_WORDS: ${{ secrets.seedWords }} | |
NEVERMINED_NODE_URI: http://node.nevermined.localnet | |
WEB3_PROVIDER_URL: http://contracts.nevermined.localnet | |
run: | | |
yarn run integration:compute | |
compute-integration: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- uses: nevermined-io/[email protected] | |
with: | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
opengsn: 'true' | |
estuary: 'true' | |
compute: 'true' | |
contracts-version: 'v3.2.1' | |
node-version: 'v1.2.9' | |
- name: Install dependencies | |
run: | | |
yarn | |
- name: Check artifacts | |
run: | | |
nvm-tools copy-artifacts ./artifacts | |
ls -l artifacts | |
- name: Run compute integration tests | |
env: | |
SEED_WORDS: ${{ secrets.seedWords }} | |
NEVERMINED_NODE_URI: http://node.nevermined.localnet | |
WEB3_PROVIDER_URL: http://contracts.nevermined.localnet | |
run: | | |
yarn run integration:compute | |
integration: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- uses: nevermined-io/[email protected] | |
with: | |
token: ${{ secrets.API_TOKEN_GITHUB }} | |
opengsn: 'true' | |
estuary: 'true' | |
compute: 'true' | |
contracts-version: 'v3.2.1' | |
node-version: 'v1.2.9' | |
- name: Install dependencies | |
run: | | |
yarn | |
- name: Check artifacts | |
run: | | |
nvm-tools copy-artifacts ./artifacts | |
ls -l artifacts | |
- name: Run integration tests | |
env: | |
SEED_WORDS: ${{ secrets.seedWords }} | |
INFURA_TOKEN: ${{ secrets.INFURA_TOKEN }} | |
IPFS_GATEWAY: https://ipfs.infura.io:5001 | |
IPFS_PROJECT_ID: ${{ secrets.IPFS_PROJECT_ID }} | |
IPFS_PROJECT_SECRET: ${{ secrets.IPFS_PROJECT_SECRET }} | |
LOG_LEVEL: 1 # If LOG_LEVEL is >1 it will print the logger.debug calls | |
run: yarn run integration:cover | |
mumbai-integration: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- name: Install dependencies | |
run: | | |
yarn | |
- name: Download artifacts | |
run: | | |
mkdir -p node_modules/@nevermined-io/contracts/artifacts | |
yarn artifacts:download v3.2.1 mumbai public | |
ls -l node_modules/@nevermined-io/contracts/artifacts | |
- name: Run nightly tests | |
env: | |
SEED_WORDS: ${{ secrets.TEST_MNEMONIC_NIGHTLY }} | |
INFURA_TOKEN: ${{ secrets.INFURA_TOKEN }} | |
IPFS_GATEWAY: https://ipfs.infura.io:5001 | |
GRAPH_DELAY: 'true' | |
IPFS_PROJECT_ID: ${{ secrets.IPFS_PROJECT_ID }} | |
IPFS_PROJECT_SECRET: ${{ secrets.IPFS_PROJECT_SECRET }} | |
run: | | |
yarn integration:e2e:mumbai |