[CI] Refactor Jenkins CI pipeline + migrate all Linux tests to Jenkins (#4401)
* All Linux tests are now in Jenkins CI * Tests are now de-coupled from builds. We can now build XGBoost with one version of CUDA/JDK and test it with another version of CUDA/JDK * Builds (compilation) are significantly faster because 1) They use C5 instances with faster CPU cores; and 2) build environment setup is cached using Docker containers
This commit is contained in:
committed by
GitHub
parent
995698b0cb
commit
ea850ecd20
45
tests/ci_build/test_python.sh
Executable file
45
tests/ci_build/test_python.sh
Executable file
@@ -0,0 +1,45 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
set -x
|
||||
|
||||
suite=$1
|
||||
|
||||
# Install XGBoost Python package
|
||||
wheel_found=0
|
||||
for file in python-package/dist/*.whl
|
||||
do
|
||||
pip install --user ${file}
|
||||
wheel_found=1
|
||||
break # need just one
|
||||
done
|
||||
if [ "$wheel_found" -eq 0 ]
|
||||
then
|
||||
pushd .
|
||||
cd python-package
|
||||
python setup.py install --user
|
||||
popd
|
||||
fi
|
||||
|
||||
# Run specified test suite
|
||||
case "$suite" in
|
||||
gpu)
|
||||
pytest -v -s --fulltrace -m "(not slow) and (not mgpu)" tests/python-gpu
|
||||
;;
|
||||
|
||||
mgpu)
|
||||
pytest -v -s --fulltrace -m "(not slow) and mgpu" tests/python-gpu
|
||||
cd tests/distributed
|
||||
./runtests-gpu.sh
|
||||
;;
|
||||
|
||||
cpu)
|
||||
pytest -v -s --fulltrace tests/python
|
||||
cd tests/distributed
|
||||
./runtests.sh
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Usage: $0 {gpu|mgpu|cpu}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
Reference in New Issue
Block a user