]>
Commit | Line | Data |
---|---|---|
522354d7 LS |
1 | language: c |
2 | ||
ce59dffb LS |
3 | sudo: false |
4 | ||
6272ed31 LS |
5 | cache: |
6 | directories: | |
7 | - $HOME/travis-cache | |
8 | ||
522354d7 LS |
9 | os: |
10 | - linux | |
11 | - osx | |
12 | ||
13 | compiler: | |
14 | - clang | |
15 | - gcc | |
16 | ||
17 | addons: | |
18 | apt: | |
19 | packages: | |
20 | - language-pack-is | |
e7e9f5e7 | 21 | - git-svn |
d9d14268 | 22 | - apache2 |
522354d7 LS |
23 | |
24 | env: | |
25 | global: | |
658df95a | 26 | - DEVELOPER=1 |
3d319f2c LS |
27 | # The Linux build installs the defined dependency versions below. |
28 | # The OS X build installs the latest available versions. Keep that | |
29 | # in mind when you encounter a broken OS X build! | |
5f703e8f LS |
30 | - LINUX_P4_VERSION="16.2" |
31 | - LINUX_GIT_LFS_VERSION="1.5.2" | |
522354d7 | 32 | - DEFAULT_TEST_TARGET=prove |
6272ed31 | 33 | - GIT_PROVE_OPTS="--timer --jobs 3 --state=failed,slow,save" |
041c72de | 34 | - GIT_TEST_OPTS="--verbose-log" |
522354d7 LS |
35 | - GIT_TEST_CLONE_2GB=YesPlease |
36 | # t9810 occasionally fails on Travis CI OS X | |
37 | # t9816 occasionally fails with "TAP out of sequence errors" on Travis CI OS X | |
38 | - GIT_SKIP_TESTS="t9810 t9816" | |
39 | ||
b98712b9 LS |
40 | matrix: |
41 | include: | |
42 | - env: Documentation | |
43 | os: linux | |
44 | compiler: clang | |
45 | addons: | |
46 | apt: | |
47 | packages: | |
48 | - asciidoc | |
49 | - xmlto | |
50 | before_install: | |
51 | before_script: | |
52 | script: ci/test-documentation.sh | |
53 | after_failure: | |
54 | ||
522354d7 LS |
55 | before_install: |
56 | - > | |
57 | case "${TRAVIS_OS_NAME:-linux}" in | |
58 | linux) | |
a296bc01 LS |
59 | export GIT_TEST_HTTPD=YesPlease |
60 | ||
522354d7 LS |
61 | mkdir --parents custom/p4 |
62 | pushd custom/p4 | |
3d319f2c LS |
63 | wget --quiet http://filehost.perforce.com/perforce/r$LINUX_P4_VERSION/bin.linux26x86_64/p4d |
64 | wget --quiet http://filehost.perforce.com/perforce/r$LINUX_P4_VERSION/bin.linux26x86_64/p4 | |
522354d7 LS |
65 | chmod u+x p4d |
66 | chmod u+x p4 | |
67 | export PATH="$(pwd):$PATH" | |
68 | popd | |
69 | mkdir --parents custom/git-lfs | |
70 | pushd custom/git-lfs | |
3d319f2c LS |
71 | wget --quiet https://github.com/github/git-lfs/releases/download/v$LINUX_GIT_LFS_VERSION/git-lfs-linux-amd64-$LINUX_GIT_LFS_VERSION.tar.gz |
72 | tar --extract --gunzip --file "git-lfs-linux-amd64-$LINUX_GIT_LFS_VERSION.tar.gz" | |
73 | cp git-lfs-$LINUX_GIT_LFS_VERSION/git-lfs . | |
522354d7 LS |
74 | export PATH="$(pwd):$PATH" |
75 | popd | |
76 | ;; | |
77 | osx) | |
78 | brew_force_set_latest_binary_hash () { | |
79 | FORMULA=$1 | |
80 | SHA=$(brew fetch --force $FORMULA 2>&1 | grep ^SHA256: | cut -d ' ' -f 2) | |
81 | sed -E -i.bak "s/sha256 \"[0-9a-f]{64}\"/sha256 \"$SHA\"/g" \ | |
f86f49be | 82 | "$(brew --repository homebrew/homebrew-binary)/$FORMULA.rb" |
522354d7 LS |
83 | } |
84 | brew update --quiet | |
85 | brew tap homebrew/binary --quiet | |
86 | brew_force_set_latest_binary_hash perforce | |
87 | brew_force_set_latest_binary_hash perforce-server | |
e3efa94b JS |
88 | # Uncomment this if you want to run perf tests: |
89 | # brew install gnu-time | |
522354d7 LS |
90 | brew install git-lfs perforce-server perforce gettext |
91 | brew link --force gettext | |
92 | ;; | |
93 | esac; | |
94 | echo "$(tput setaf 6)Perforce Server Version$(tput sgr0)"; | |
95 | p4d -V | grep Rev.; | |
96 | echo "$(tput setaf 6)Perforce Client Version$(tput sgr0)"; | |
97 | p4 -V | grep Rev.; | |
98 | echo "$(tput setaf 6)Git-LFS Version$(tput sgr0)"; | |
99 | git-lfs version; | |
6272ed31 LS |
100 | mkdir -p $HOME/travis-cache; |
101 | ln -s $HOME/travis-cache/.prove t/.prove; | |
522354d7 LS |
102 | |
103 | before_script: make --jobs=2 | |
104 | ||
105 | script: make --quiet test | |
106 | ||
107 | after_failure: | |
108 | - > | |
109 | : '<-- Click here to see detailed test output! '; | |
110 | for TEST_EXIT in t/test-results/*.exit; | |
111 | do | |
112 | if [ "$(cat "$TEST_EXIT")" != "0" ]; | |
113 | then | |
114 | TEST_OUT="${TEST_EXIT%exit}out"; | |
115 | echo "------------------------------------------------------------------------"; | |
116 | echo "$(tput setaf 1)${TEST_OUT}...$(tput sgr0)"; | |
117 | echo "------------------------------------------------------------------------"; | |
118 | cat "${TEST_OUT}"; | |
119 | fi; | |
120 | done; | |
121 | ||
122 | notifications: | |
123 | email: false |