8000 Add a Travis configuration file · python/cpython@bb09c86 · GitHub
[go: up one dir, main page]

Skip to content
8000

Commit bb09c86

Browse files
authored
Add a Travis configuration file
1 parent 6f0eb93 commit bb09c86

File tree

1 file changed

+81
-0
lines changed

1 file changed

+81
-0
lines changed

.travis.yml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
language: c
2+
dist: trusty
3+
sudo: false
4+
group: beta
5+
6+
# To cache doc-building dependencies.
7+
cache: pip
8+
9+
os:
10+
- linux
11+
# macOS builds are disabled as the machines are under-provisioned on Travis,
12+
# adding up to an extra hour completing a full CI run.
13+
#- osx
14+
15+
compiler:
16+
- clang
17+
- gcc
18+
19+
env:
20+
- TESTING=cpython
21+
22+
matrix:
23+
allow_failures:
24+
- env:
25+
- TESTING=coverage
26+
include:
27+
- os: linux
28+
language: python
29+
python: 3.5
30+
env:
31+
- TESTING=docs
32+
before_script:
33+
- cd Doc
34+
- make venv PYTHON=python3
35+
script:
36+
- make html SPHINXBUILD="./venv/bin/python3 -m sphinx" SPHINXOPTS="-nW -q -b linkcheck"
37+
- os: linux
38+
language: c
39+
compiler: clang
40+
env:
41+
- TESTING=coverage
42+
before_script:
43+
- ./configure
44+
- make -s -j4
45+
# Need a venv that can parse covered code.
46+
- ./python -m venv venv
47+
- ./venv/bin/python -m pip install -U coverage
48+
script:
49+
# Skip tests that re-run the entire test suite.
50+
- ./venv/bin/python -m coverage run --pylib -m test -uall -x test_multiprocessing_fork -x test_multiprocessing_forkserver -x test_multiprocessing_spawn
51+
after_script: # Probably should be after_success once test suite updated to run under coverage.py.
52+
# Make the `coverage` command available to Codecov w/ a version of Python that can parse all source files.
53+
- source ./venv/bin/activate
54+
- bash <(curl -s https://codecov.io/bash)
55+
- os: linux
56+
language: cpp
57+
compiler: clang
58+
env:
59+
- TESTING="C++ header compatibility"
60+
before_script:
61+
- ./configure
62+
script:
63+
- echo '#include "Python.h"' > test.cc && $CXX -c test.cc -o /dev/null -I ./Include -I .
64+
65+
# Travis provides only 2 cores, so don't overdue the parallelism and waste memory.
66+
before_script:
67+
- ./configure --with-pydebug
68+
- make -j4
69+
70+
script:
71+
# `-r -w` implicitly provided through `make buildbottest`.
72+
- make buildbottest TESTOPTS="-j4"
73+
74+
notifications:
75+
email: false
76+
irc:
77+
channels:
78+
- "irc.freenode.net#python-dev"
79+
on_success: change
80+
on_failure: always
81+
skip_join: true

0 commit comments

Comments
 (0)
0