mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-10-24 12:13:33 +08:00
Unit test Galaxy packages during CI.
All the same unit tests run in the context of a full Galaxy but this will ensure the tests also run with their dependencies as would be configured via pip-installed variants. This will catch dependency problems and ensure the package dependency structure remains correct.
This commit is contained in:
@@ -154,6 +154,13 @@ jobs:
|
||||
- run: sudo apt-get install -y libxml2-utils
|
||||
- *install_tox
|
||||
- run: tox -e validate_test_tools
|
||||
test_galaxy_packages:
|
||||
docker:
|
||||
- image: circleci/python:2.7.15
|
||||
<<: *set_workdir
|
||||
steps:
|
||||
- *restore_repo_cache
|
||||
- run: sh packages/test.sh
|
||||
check_py3_compatibility:
|
||||
docker:
|
||||
- image: circleci/python:2.7.15
|
||||
@@ -202,6 +209,8 @@ workflows:
|
||||
<<: *requires_get_code
|
||||
- py35_first_startup:
|
||||
<<: *requires_get_code
|
||||
- test_galaxy_packages:
|
||||
<<: *requires_get_code
|
||||
- validate_test_tools:
|
||||
<<: *requires_get_code
|
||||
- check_py3_compatibility:
|
||||
|
||||
Executable
+27
@@ -0,0 +1,27 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
|
||||
# Change to packages directory.
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
TEST_PYTHON=${TEST_PYTHON:-"python"}
|
||||
TEST_ENV_DIR=${TEST_ENV_DIR:-`mktemp -d -t gxpkgtestenvXXXXXX`}
|
||||
|
||||
virtualenv -p "$TEST_PYTHON" "$TEST_ENV_DIR"
|
||||
. "${TEST_ENV_DIR}/bin/activate"
|
||||
pip install pytest
|
||||
|
||||
# ensure ordered by dependency dag
|
||||
PACKAGE_DIRS="
|
||||
util
|
||||
objectstore
|
||||
data
|
||||
"
|
||||
|
||||
for package_dir in $PACKAGE_DIRS; do
|
||||
cd "$package_dir"
|
||||
python setup.py install
|
||||
pytest --doctest-modules galaxy tests
|
||||
cd ..
|
||||
done
|
||||
Reference in New Issue
Block a user