2019-05-06 18:56:44 +03:00
|
|
|
language: python
|
|
|
|
dist: xenial
|
2019-09-28 06:44:02 +03:00
|
|
|
sudo: required
|
|
|
|
python:
|
|
|
|
- "3.7"
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
sources: ['ubuntu-toolchain-r-test']
|
|
|
|
packages: ['bash', 'coreutils', 'awscli']
|
2019-09-27 21:12:33 +03:00
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- /home/travis/.nvm
|
|
|
|
- /home/travis/.cache/pip
|
2019-05-06 18:56:44 +03:00
|
|
|
env:
|
2019-05-06 20:42:36 +03:00
|
|
|
global:
|
2019-08-01 17:14:18 +03:00
|
|
|
- BOTO_CONFIG: "/dev/null"
|
2019-09-28 06:44:02 +03:00
|
|
|
- LOG_LEVEL: ERROR
|
2019-08-01 17:14:18 +03:00
|
|
|
- AWS_XRAY_SDK_ENABLED: false
|
2019-09-18 18:02:22 +03:00
|
|
|
- DEPLOYED_ENV: travis
|
2019-08-09 21:27:11 +03:00
|
|
|
|
2019-05-06 18:56:44 +03:00
|
|
|
before_install:
|
2019-08-01 17:14:18 +03:00
|
|
|
- sudo rm -f /etc/boto.cfg
|
|
|
|
- pip install -r automation_requirements.txt
|
|
|
|
- npm install -g dynalite
|
|
|
|
- npm install -g kinesalite
|
2019-09-18 18:02:22 +03:00
|
|
|
- sudo apt-get install -y awscli
|
|
|
|
- ./bin/aws-credentials.sh
|
2019-08-02 04:52:44 +03:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
include:
|
2019-09-18 18:02:22 +03:00
|
|
|
- stage: Unit Tests
|
2019-08-02 04:52:44 +03:00
|
|
|
script:
|
2019-09-28 06:44:02 +03:00
|
|
|
# The below 2 TravisCI statements are a workaround for an issue in TravisCI which
|
|
|
|
# is best described as "Large writes to stdout sometimes fail with "Resource temporarily unavailable".
|
|
|
|
# More information about this can be found at:
|
|
|
|
# https://github.com/travis-ci/travis-ci/issues/4704#issuecomment-348435959
|
|
|
|
#
|
|
|
|
# Turn off O_NONBLOCK:
|
|
|
|
- python3.7 -c 'import os,sys,fcntl; flags = fcntl.fcntl(sys.stdout, fcntl.F_GETFL);
|
|
|
|
fcntl.fcntl(sys.stdout, fcntl.F_SETFL, flags&~os.O_NONBLOCK);'
|
|
|
|
# Check whether O_NONBLOCK is set (should print "0"):
|
|
|
|
- python3.7 -c 'import os,sys,fcntl; flags = fcntl.fcntl(sys.stdout, fcntl.F_GETFL);
|
|
|
|
print(flags&os.O_NONBLOCK);'
|
2019-08-25 02:03:33 +03:00
|
|
|
- doit test
|
2019-09-30 05:27:49 +03:00
|
|
|
- cd /home/travis/build/mozilla/subhub/src/sub && bash <(curl -s https://codecov.io/bash) -cF python
|
|
|
|
- cd /home/travis/build/mozilla/subhub/src/hub && bash <(curl -s https://codecov.io/bash) -cF python
|