#!/bin/bash
set -e

pkg=baitfisher

if [ "${AUTOPKGTEST_TMP}" = "" ] ; then
  AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
  trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM
fi

cp /usr/share/doc/${pkg}/examples/* -a "${AUTOPKGTEST_TMP}"

cd "${AUTOPKGTEST_TMP}"
gunzip -r *

ls
echo 'Test 1'
cd Example-without-alignment-cutting
mkdir -p BaitFisher-results 
BaitFisher parameter.txt
for f in BaitFisher-results/*
do
	echo "Checking if $f is not empty"
	[ -s $f ] || exit 1
done
echo 'PASS'
echo

