Add mercurial package, used as test dependency
This commit is contained in:
@@ -13,16 +13,37 @@
|
||||
|
||||
for dep in "$@"; do
|
||||
if ! which $dep &> /dev/null; then
|
||||
# sphinx-build comes from sphinx
|
||||
package=$(echo $dep | cut -d - -f 1)
|
||||
# Map binary name to package name
|
||||
case $dep in
|
||||
sphinx-apidoc|sphinx-build)
|
||||
spack_package=py-sphinx
|
||||
pip_package=sphinx
|
||||
;;
|
||||
coverage)
|
||||
spack_package=py-coverage
|
||||
pip_package=coverage
|
||||
;;
|
||||
flake8)
|
||||
spack_package=py-flake8
|
||||
pip_package=flake8
|
||||
;;
|
||||
hg)
|
||||
spack_package=py-mercurial
|
||||
pip_package=mercurial
|
||||
;;
|
||||
*)
|
||||
spack_package=$dep
|
||||
pip_package=$dep
|
||||
;;
|
||||
esac
|
||||
|
||||
cat << EOF
|
||||
ERROR: $package is required to run this script.
|
||||
ERROR: $dep is required to run this script.
|
||||
|
||||
To install with Spack, run:
|
||||
$ spack install py-$package
|
||||
$ spack install $spack_package
|
||||
or, to install with pip, run:
|
||||
$ pip install $package
|
||||
$ pip install $pip_package
|
||||
Then add the bin directory to your PATH.
|
||||
EOF
|
||||
exit 1
|
||||
|
@@ -18,6 +18,7 @@ DOC_DIR="$SPACK_ROOT/lib/spack/docs"
|
||||
|
||||
# Array of dependencies
|
||||
deps=(
|
||||
sphinx-apidoc
|
||||
sphinx-build
|
||||
hg
|
||||
)
|
||||
|
@@ -20,6 +20,7 @@ SPACK_ROOT="$QA_DIR/../../.."
|
||||
# Array of dependencies
|
||||
deps=(
|
||||
coverage
|
||||
hg
|
||||
)
|
||||
|
||||
# Check for dependencies
|
||||
@@ -28,6 +29,10 @@ deps=(
|
||||
# Add Spack to the PATH.
|
||||
export PATH="$SPACK_ROOT/bin:$PATH"
|
||||
|
||||
# Move to root directory of Spack
|
||||
# Allows script to be run from anywhere
|
||||
cd "$SPACK_ROOT"
|
||||
|
||||
# Array of directories containing core Spack framework
|
||||
core_dirs=(
|
||||
bin
|
||||
@@ -57,4 +62,4 @@ spack config get compilers
|
||||
spack install -v libdwarf
|
||||
|
||||
# Run unit tests with code coverage
|
||||
coverage run spack test "$@"
|
||||
coverage run bin/spack test "$@"
|
||||
|
Reference in New Issue
Block a user