| 1 |
#!/bin/bash |
| 2 |
set -e |
| 3 |
|
| 4 |
pkg=python3-biom-format |
| 5 |
|
| 6 |
if [ "${AUTOPKGTEST_TMP}" = "" ] ; then |
| 7 |
AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX) |
| 8 |
# Double quote below to expand the temporary directory variable now versus |
| 9 |
# later is on purpose. |
| 10 |
# shellcheck disable=SC2064 |
| 11 |
trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM |
| 12 |
fi |
| 13 |
|
| 14 |
cp -a /usr/share/doc/${pkg}/examples "${AUTOPKGTEST_TMP}" |
| 15 |
|
| 16 |
cd "${AUTOPKGTEST_TMP}" |
| 17 |
|
| 18 |
biom show-install-info |
| 19 |
# we can only validate the tables if we have H5PY |
| 20 |
for table in examples/*hdf5.biom; do |
| 21 |
biom validate-table -i ${table} |
| 22 |
done |
| 23 |
|
| 24 |
# validate JSON formatted tables |
| 25 |
for table in examples/*table.biom; do |
| 26 |
biom validate-table -i ${table} |
| 27 |
done |
| 28 |
|
| 29 |
python3 /usr/lib/python3/dist-packages/biom/assets/exercise_api.py examples/rich_sparse_otu_table_hdf5.biom sample |
| 30 |
python3 /usr/lib/python3/dist-packages/biom/assets/exercise_api.py examples/rich_sparse_otu_table_hdf5.biom observation |
| 31 |
sh /usr/lib/python3/dist-packages/biom/assets/exercise_cli.sh |