forked from cocotb/cocotb
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
43 lines (38 loc) · 1.36 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# See Dockerfile for the full build instructions
sudo: required
language: python
cache: pip
# mainly for flake8 as everything else runs in docker
python:
- 3.5
git:
quiet: true
services:
- docker
jobs:
include:
- stage: PythonLint
install: pip install flake8
script: flake8 --exit-zero cocotb/
- stage: SimTests
# env only here for easier visibility in travis-ci
env:
- COCOTB_PY27
before_install: &docker_prep
- docker build -t cocotb .
- docker images -a
- docker run -d --name cocotb cocotb tail -f /dev/null
- docker ps -a
script:
- echo 'Running cocotb tests with Python 2.7 ...' && echo 'travis_fold:start:cocotb_py27'
- docker exec -it -e TRAVIS=true -e COCOTB=/build-py2/src cocotb bash -lc 'source /build-py2/venv/bin/activate; make -C /build-py2/src test'
- echo -e 'travis_fold:end:cocotb_py27'
- stage: SimTests
# env only here for easier visibility in travis-ci
env:
- COCOTB_PY35
before_install: *docker_prep
script:
- echo 'Running cocotb tests with Python 3.5 ...' && echo -en 'travis_fold:start:cocotb_py35'
- docker exec -it -e TRAVIS=true -e COCOTB=/build-py3/src cocotb bash -lc 'set -x; source /build-py3/venv/bin/activate; make -C /build-py3/src test'
- echo 'travis_fold:end:cocotb_py35'