squid-js/.travis.yml

58 lines
1.7 KiB
YAML

dist: xenial
sudo: required
language: node_js
node_js:
- '12'
services:
- docker
cache: npm
matrix:
fast_finish: true
before_install:
- npm install -g npm
- npm install -g ganache-cli@~6.5.1
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
before_script:
- ganache-cli --port 18545 > ganache-cli.log &
- git clone https://github.com/oceanprotocol/barge
- cd barge
- export AQUARIUS_VERSION=v1.1.0
- export BRIZO_VERSION=v0.9.7
- export KEEPER_VERSION=v0.13.2
- export EVENTS_HANDLER_VERSION=v0.4.7
- export KEEPER_OWNER_ROLE_ADDRESS="0xe2DD09d719Da89e5a3D0F2549c7E24566e947260"
- rm -rf "${HOME}/.ocean/keeper-contracts/artifacts"
- bash -x start_ocean.sh --no-commons --no-dashboard 2>&1 > start_ocean.log &
- cd ..
script:
- npm run lint
- ./scripts/keeper.sh
- export ETH_PORT=18545; npm run test:cover
- npm run build
- npm run doc
- npm run test:integration:cover
after_script:
- ./cc-test-reporter format-coverage -t lcov -o coverage/codeclimate.unit.json coverage/unit/lcov.info # Format unit test coverage
- ./cc-test-reporter format-coverage -t lcov -o coverage/codeclimate.integration.json coverage/integration/lcov.info # Format integration test coverage
- ./cc-test-reporter sum-coverage coverage/codeclimate.*.json -p 2 # Sum both coverage parts into coverage/codeclimate.json
- if [[ "$TRAVIS_TEST_RESULT" == 0 ]]; then ./cc-test-reporter upload-coverage; fi # Upload coverage/codeclimate.json
notifications:
email: false
deploy:
- provider: npm
email: 'devops@oceanprotocol.com'
api_key: ${NPM_TOKEN}
skip_cleanup: true
on:
tags: true