forked from oscar-system/GAP.jl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
90 lines (81 loc) · 2.54 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
language: julia
julia:
- 1.1
- 1.2
- 1.3
- nightly
env:
global:
- MAKEFLAGS="-j4"
- JULIA_TRACK_COVERAGE=yes
- PATH="/usr/lib/ccache:$PATH"
matrix:
- GAP_INSTALL_PACKAGES=debug
- GAPROOT=$TRAVIS_BUILD_DIR/gap
addons:
apt_packages:
- libgmp-dev
- libreadline-dev
- zlib1g-dev
branches:
only:
- master
install:
# install some optional dependencies for our tests
- JULIA_PROJECT= julia -e 'import Pkg ; Pkg.add("Nemo")'
- JULIA_PROJECT= julia -e 'import Pkg ; Pkg.add("Primes")'
- JULIA_PROJECT= julia -e 'import Pkg ; Pkg.add("LinearAlgebra")'
- JULIA_PROJECT= julia -e 'import Pkg ; Pkg.add("Singular")'
# install GAP "manually" if requested
- if [[ -v GAPROOT ]]; then etc/travis_install_gap.sh; fi
before_script:
# check code formatting
- git ls-files | egrep '\.[ch]$' | xargs clang-format -i
- git diff --exit-code -- . # detect if there are any diffs
script:
# enable coverage tracking in our C code
- mkdir -p coverage
- export CFLAGS=--coverage; export LDFLAGS=--coverage
# Build package and run Julia specific tests
- julia --color=yes -e 'using Pkg ; Pkg.build(; verbose = true)'
- julia --color=yes -e 'using Pkg ; Pkg.test(coverage=true)'
- pkgpath=$(julia -e 'print(abspath(joinpath(dirname(Base.find_package("GAP")), "..")))');
# Run GAP specific tests
- export GAP="$pkgpath/gap.sh -A --quitonbreak --norepl"
- etc/travis_test.sh
# delete *.gcno and *.gcda coverage files for GAP C files, to avoid clash
# with our .c files such as calls.c
- if [[ -v GAPROOT ]]; then
rm -f $GAPROOT/obj/src/.libs/*.gc* ;
else
rm -f $pkgpath/gap/obj/src/.libs/*.gc* ;
fi
after_script:
- cd $TRAVIS_BUILD_DIR
- $GAP etc/gather_coverage.g
- rm -rf gap # delete GAP if present, to avoid collecting its coverage data
- julia --color=yes etc/gather_coverage.jl
- bash <(curl -s https://codecov.io/bash)
jobs:
include:
- stage: "Documentation"
julia: 1.1
os: linux
script:
- julia --color=yes --project=docs/ -e 'using Pkg; Pkg.instantiate(); Pkg.add(PackageSpec(path=pwd()))'
- julia --color=yes --project=docs/ docs/make.jl
after_success: skip
name: "HTML"
notifications:
email:
recipients:
on_success: never # default: change
on_failure: always # default: always
slack:
on_pull_requests: false
on_success: change
on_failure: always
rooms:
- 'oscar-system:gu1s3knwtSUWV1NaeVb0QJpD#gapjulia'
- 'oscar-system:gu1s3knwtSUWV1NaeVb0QJpD#travis'