forked from cmu-db/peloton
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
90 lines (85 loc) · 3.12 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: c++
python: 3.6
matrix:
fast_finish: true
include:
# Mac build
- os: osx
osx_image: xcode8.3
compiler: clang
env:
# NAME has no actual use, just to make the travis jobs overview more clear
- NAME="clang Debug/Tests/AddressSanitizer"
- PELOTON_BUILD_TYPE=Debug
- SANITIZER=Address
- COVERALLS=Off
- LLVM_DIR=/usr/local/Cellar/llvm@3.9/3.9.1_2
# Linux builds for gcc 5
- os: linux
sudo: required
dist: trusty
compiler: gcc
addons:
apt:
sources:
- llvm-toolchain-precise-3.7
- ubuntu-toolchain-r-test
packages:
- g++-5
env:
# NAME has no actual use, just to make the travis jobs overview more clear
- NAME="gcc5 Debug/Tests/AddressSanitizer/Coveralls"
- CXX=g++-5
- CC=gcc-5
- PELOTON_BUILD_TYPE=Debug
- SANITIZER=Address
- COVERALLS=On
- os: linux
sudo: required
dist: trusty
compiler: gcc
addons:
apt:
sources:
- llvm-toolchain-precise-3.7
- ubuntu-toolchain-r-test
packages:
- g++-5
env:
# NAME has no actual use, just to make the travis jobs overview more clear
- NAME="gcc5 Release/Tests/AddressSanitizer"
- CXX=g++-5
- CC=gcc-5
- PELOTON_BUILD_TYPE=Release
- SANITIZER=
- COVERALLS=Off
install:
# setup environment
- ./script/installation/packages.sh
- if [[ $TRAVIS_OS_NAME == 'linux' ]]; then pip install --user cpp-coveralls; fi
before_script:
# first, run source_validator
- python script/validators/source_validator.py
# build peloton (override this value to execute tests)
script:
# create build directory
- mkdir build
- cd build
# run cmake. NOTE: the PATH is made explicit to avoid automatic selection of the preinstalled llvm version in the Travis trusty image
- PATH=/usr/lib/llvm-3.7/bin:/usr/bin:$PATH cmake -DCOVERALLS=$COVERALLS -DCMAKE_BUILD_TYPE=$PELOTON_BUILD_TYPE -DUSE_SANITIZER=$SANITIZER ..
# build
- make -j4
# run tests
- if [[ $TRAVIS_OS_NAME != 'osx' ]]; then make check -j4; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then ASAN_OPTIONS=detect_container_overflow=0 make check -j4; fi
# install peloton
- make install
# run psql tests
- bash ../script/testing/psql/psql_test.sh
# run jdbc tests
- python ../script/validators/jdbc_validator.py
# run junit tests
- if [[ $TRAVIS_OS_NAME != 'osx' ]]; then python ../script/testing/junit/run_junit.py; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then ASAN_OPTIONS=detect_container_overflow=0 python ../script/testing/junit/run_junit.py; fi
# upload coverage info
- if [[ $COVERALLS == 'On' ]]; then make coveralls; fi