@@ -11,46 +11,46 @@ branches:
1111 - master
1212 - /^\d\.\d$/
1313
14- os :
15- - linux
16- # macOS builds are disabled as the machines are under-provisioned on Travis,
17- # adding up to an extra hour completing a full CI run.
18-
19- compiler :
20- - clang
21- # gcc also works, but to keep the # of concurrent builds down, we use one C
22- # compiler here and the other to run the coverage build.
23-
24- env :
25- - TESTING=cpython
26-
2714matrix :
2815 fast_finish : true
2916 allow_failures :
30- - env :
31- - TESTING=coverage
17+ - env : OPTIONAL=true
3218 include :
19+ - os : linux
20+ language : c
21+ compiler : clang
22+ # gcc also works, but to keep the # of concurrent builds down, we use one C
23+ # compiler here and the other to run the coverage build. Clang is preferred
24+ # in this instance for its better error messages.
25+ env : TESTING=cpython
26+ - os : osx
27+ language : c
28+ compiler : clang
29+ # Testing under macOS is optional until testing stability has been demonstrated.
30+ env : OPTIONAL=true
31+ before_install :
32+ - brew install openssl xz
33+ - export CPPFLAGS="-I$(brew --prefix openssl)/include"
34+ - export LDFLAGS="-L$(brew --prefix openssl)/lib"
3335 - os : linux
3436 language : python
3537 # Build the docs against a stable version of Python so code bugs don't hold up doc-related PRs.
3638 python : 3.6
37- env :
38- - TESTING=docs
39+ env : TESTING=docs
3940 before_script :
4041 - cd Doc
4142 # Sphinx is pinned so that new versions that introduce new warnings won't suddenly cause build failures.
4243 # (Updating the version is fine as long as no warnings are raised by doing so.)
4344 - python -m pip install sphinx~=1.6.1
4445 script :
45- - make check suspicious html SPHINXOPTS="-q -W"
46+ - make check suspicious html SPHINXOPTS="-q -W -j4 "
4647 - os : linux
4748 language : c
4849 compiler : gcc
49- env :
50- - TESTING=coverage
50+ env : OPTIONAL=true
5151 before_script :
5252 - |
53- if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.( rst|yml) $)|(^Doc)|(^Misc)/ '
53+ if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.rst$)|(^Doc)|(^Misc)'
5454 then
5555 echo "Only docs were updated, stopping build process."
5656 exit
@@ -62,26 +62,40 @@ matrix:
6262 ./venv/bin/python -m pip install -U coverage
6363 script :
6464 # Skip tests that re-run the entire test suite.
65- - ./venv/bin/python -m coverage run --pylib -m test -uall -x test_multiprocessing_fork -x test_multiprocessing_forkserver -x test_multiprocessing_spawn
65+ - ./venv/bin/python -m coverage run --pylib -m test -uall,-cpu -x test_multiprocessing_fork -x test_multiprocessing_forkserver -x test_multiprocessing_spawn
6666 after_script : # Probably should be after_success once test suite updated to run under coverage.py.
6767 # Make the `coverage` command available to Codecov w/ a version of Python that can parse all source files.
6868 - source ./venv/bin/activate
6969 - bash <(curl -s https://codecov.io/bash)
7070
71- # Travis provides only 2 cores, so don't overdue the parallelism and waste memory.
71+ # Travis provides only 2 cores, so don't overdo the parallelism and waste memory.
7272before_script :
7373 - |
74- if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.(rst|yml)$)|(^Doc)|(^Misc)/'
74+ set -e
75+ if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.rst$)|(^Doc)|(^Misc)'
7576 then
7677 echo "Only docs were updated, stopping build process."
7778 exit
7879 fi
7980 ./configure --with-pydebug
8081 make -j4
82+ make -j4 regen-all clinic
83+ changes=`git status --porcelain`
84+ if ! test -z "$changes"
85+ then
86+ echo "Generated files not up to date"
87+ echo "$changes"
88+ exit 1
89+ fi
8190
8291script :
92+ # Using the built Python as patchcheck.py is built around the idea of using
93+ # a checkout-build of CPython to know things like what base branch the changes
94+ # should be compared against.
95+ # Only run on Linux as the check only needs to be run once.
96+ - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then ./python Tools/scripts/patchcheck.py --travis $TRAVIS_PULL_REQUEST; fi
8397 # `-r -w` implicitly provided through `make buildbottest`.
84- - make buildbottest TESTOPTS="-j4"
98+ - make buildbottest TESTOPTS="-j4 -uall,-cpu "
8599
86100notifications :
87101 email : false
0 commit comments