File: .travis.yml

package info (click to toggle)
python-bioblend 0.7.0-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 800 kB
  • sloc: python: 5,195; sh: 217; makefile: 139
file content (59 lines) | stat: -rw-r--r-- 3,414 bytes parent folder | download | duplicates (2)
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
sudo: false
language: python
python:
  - "2.7"
env:
  - TOX_ENV=py34 GALAXY_VERSION=dev
  - TOX_ENV=py33 GALAXY_VERSION=dev
  - TOX_ENV=py27 GALAXY_VERSION=dev
  - TOX_ENV=py27 GALAXY_VERSION=release_15.07
  - TOX_ENV=py27 GALAXY_VERSION=release_15.05
  - TOX_ENV=py27 GALAXY_VERSION=release_15.03
  - TOX_ENV=py27 GALAXY_VERSION=release_15.01
  - TOX_ENV=py27 GALAXY_VERSION=release_14.10
  - TOX_ENV=py27 GALAXY_VERSION=release_14.08
  - TOX_ENV=py27 GALAXY_VERSION=release_14.06
  - TOX_ENV=py27 GALAXY_VERSION=release_14.04
  - TOX_ENV=py27 GALAXY_VERSION=release_14.02
  - TOX_ENV=py26 GALAXY_VERSION=dev

install:
  - python setup.py install
  - cp run_galaxy.sh $HOME
  - pip install "tox>=1.8.0"

before_script:
  # Install Galaxy
  - cd $HOME
  - wget https://github.com/galaxyproject/galaxy/archive/${GALAXY_VERSION}.tar.gz
  - tar xvzf ${GALAXY_VERSION}.tar.gz | tail
  # Releases/dev branch are named differently
  - cd galaxy-${GALAXY_VERSION}/
  # Create a PostgreSQL database for Galaxy. The default SQLite3 database makes test fail randomly because of "database locked" error.
  - createdb -U postgres galaxy-travis
  - if [ -f universe_wsgi.ini.sample ]; then GALAXY_CONFIG_FILE=universe_wsgi.ini; else GALAXY_CONFIG_FILE=config/galaxy.ini; fi
  - if [ -f universe_wsgi.ini.sample ]; then GALAXY_CONFIG_DIR=.; else GALAXY_CONFIG_DIR=config; fi
  # Change Galaxy configuration to use the newly created PostgreSQL database
  - sed -e 's|^#database_connection.*|database_connection = postgresql://postgres:@localhost/galaxy-travis|' $GALAXY_CONFIG_FILE.sample > $GALAXY_CONFIG_FILE
  # Setup Galaxy master API key and admin user
  - GALAXY_MASTER_API_KEY=`date --rfc-3339=ns | md5sum | cut -f 1 -d ' '`
  - GALAXY_USER_EMAIL=${USER}@localhost.localdomain
  - sed -i -e "s/^#master_api_key.*/master_api_key = $GALAXY_MASTER_API_KEY/" -e "s/^#admin_users.*/admin_users = $GALAXY_USER_EMAIL/" $GALAXY_CONFIG_FILE
  # Change configuration needed by many tests
  - sed -i -e 's/^#allow_user_dataset_purge.*/allow_user_dataset_purge = True/' $GALAXY_CONFIG_FILE
  # Change Galaxy configuration needed by some library tests
  - sed -i -e 's/^#allow_library_path_paste.*/allow_library_path_paste = True/' $GALAXY_CONFIG_FILE
  - sed -i -e 's/^#enable_beta_workflow_modules.*/enable_beta_workflow_modules = True/' $GALAXY_CONFIG_FILE
  - if [ -f test/functional/tools/samples_tool_conf.xml ]; then sed -i -e "s/^#tool_config_file.*/tool_config_file = $GALAXY_CONFIG_DIR\/tool_conf.xml.sample,$GALAXY_CONFIG_DIR\/shed_tool_conf.xml.sample,test\/functional\/tools\/samples_tool_conf.xml/" $GALAXY_CONFIG_FILE; fi
  # Start Galaxy and wait for successful server start
  - GALAXY_RUN_ALL=1 ../run_galaxy.sh --daemon --wait
  # Use the master API key to create the admin user and get its API key
  - export BIOBLEND_GALAXY_URL=http://localhost:8080
  - GALAXY_USER=$USER
  - GALAXY_USER_PASSWD=`date --rfc-3339=ns | md5sum | cut -f 1 -d ' '`
  - export BIOBLEND_GALAXY_API_KEY=`python $TRAVIS_BUILD_DIR/docs/examples/create_user_get_api_key.py $BIOBLEND_GALAXY_URL $GALAXY_MASTER_API_KEY $GALAXY_USER $GALAXY_USER_EMAIL $GALAXY_USER_PASSWD`
  - echo "Created new Galaxy user $GALAXY_USER with email $GALAXY_USER_EMAIL , password $GALAXY_USER_PASSWD and API key $BIOBLEND_GALAXY_API_KEY"

script:
  # Run nosetests through setuptools, so it will install test depedencies
  - cd $TRAVIS_BUILD_DIR && tox -e $TOX_ENV