Mercurial > p > roundup > code
annotate .travis.yml @ 5375:1ad46057ae4a
Test against latest version of Xapian
The version of Xapian available in the Ubuntu 14.04 repositories doesn't
support python3 (Xapian >=1.3 required). The xapian-backports PPA
provides the latest version of Xapian (v1.4.7 at the time of this
commit), which does have support for python3.
| author | John Kristensen <john@jerrykan.com> |
|---|---|
| date | Sat, 21 Jul 2018 23:07:16 +1000 |
| parents | faf3f01ef446 |
| children | 17eea0eac04e |
| rev | line source |
|---|---|
| 5003 | 1 language: python |
| 2 python: | |
| 3 - 2.7 | |
|
5368
904d7cd19d67
Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents:
5259
diff
changeset
|
4 - 3.4 |
|
904d7cd19d67
Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents:
5259
diff
changeset
|
5 |
|
904d7cd19d67
Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents:
5259
diff
changeset
|
6 matrix: |
|
904d7cd19d67
Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents:
5259
diff
changeset
|
7 allow_failures: |
|
904d7cd19d67
Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents:
5259
diff
changeset
|
8 - python: 3.4 |
| 5003 | 9 |
| 10 sudo: false | |
| 11 | |
| 12 addons: | |
| 13 apt: | |
|
5375
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
14 sources: |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
15 - sourceline: ppa:xapian-backports/ppa |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
16 |
| 5003 | 17 packages: |
|
5375
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
18 # Required to build/install the xapian-binding |
|
5373
faf3f01ef446
Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents:
5372
diff
changeset
|
19 - libxapian-dev |
| 5003 | 20 # Required to install pyme |
| 21 - libgpgme11-dev | |
| 22 - swig | |
| 23 | |
| 24 before_install: | |
|
5375
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
25 # Sphinx required to build the xapian python bindings |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
26 - pip install sphinx |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
27 - XAPIAN_VER=$(dpkg -l libxapian-dev | tail -n 1 | awk '{print $3}' | cut -d '-' -f 1) |
| 5003 | 28 - cd /tmp |
|
5375
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
29 - curl -s -O https://oligarchy.co.uk/xapian/$XAPIAN_VER/xapian-bindings-$XAPIAN_VER.tar.xz |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
30 - tar -Jxvf xapian-bindings-$XAPIAN_VER.tar.xz |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
31 - cd xapian-bindings-$XAPIAN_VER/ |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
32 - if [[ $TRAVIS_PYTHON_VERSION == "2."* ]]; then ./configure --prefix=$VIRTUAL_ENV --with-python; fi |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
33 - if [[ $TRAVIS_PYTHON_VERSION == "3."* ]]; then ./configure --prefix=$VIRTUAL_ENV --with-python3; fi |
|
1ad46057ae4a
Test against latest version of Xapian
John Kristensen <john@jerrykan.com>
parents:
5373
diff
changeset
|
34 - make && make install |
| 5003 | 35 |
| 36 # change back to the checked out repository directory | |
| 37 - cd $TRAVIS_BUILD_DIR | |
| 38 | |
| 39 install: | |
|
5099
a7cf77108e97
issue2550636 instal whosh as part of travis ci to try to get indexer testing working
John Rouillard <rouilj@ieee.org>
parents:
5060
diff
changeset
|
40 - pip install MySQL-python psycopg2 pytz pyme whoosh |
|
5060
de420f34d696
Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents:
5059
diff
changeset
|
41 - pip install pytest-cov codecov |
| 5003 | 42 |
| 43 before_script: | |
| 44 # set up mysql database | |
| 45 - mysql -u root -e 'GRANT ALL ON rounduptest.* TO rounduptest@localhost IDENTIFIED BY "rounduptest";' | |
| 46 | |
| 47 # set up postgresql database | |
| 48 - psql -c "CREATE ROLE rounduptest WITH CREATEDB LOGIN PASSWORD 'rounduptest';" -U postgres | |
| 49 | |
| 50 # HACK: workaround mysql bug: http://bugs.mysql.com/bug.php?id=74901 | |
| 51 # needed for test_mysql.mysqlDBTest.testFilteringSpecialChars | |
| 52 - sed -i 's/CREATE DATABASE \%s/CREATE DATABASE \%s COLLATE utf8_general_ci/' roundup/backends/back_mysql.py | |
| 53 | |
| 54 script: | |
|
5060
de420f34d696
Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents:
5059
diff
changeset
|
55 - py.test -v test/ --cov=roundup |
|
de420f34d696
Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents:
5059
diff
changeset
|
56 |
|
de420f34d696
Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents:
5059
diff
changeset
|
57 after_success: |
|
de420f34d696
Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents:
5059
diff
changeset
|
58 - codecov |
