-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding a test script for abismal that uses two threads
- Loading branch information
1 parent
50c5051
commit ba4bfb9
Showing
1 changed file
with
47 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#!/usr/bin/env bash | ||
|
||
f () { | ||
error_code=$? # save exit code first | ||
echo "error $error_code" | ||
echo "command with error:" | ||
echo "${BASH_COMMAND}" | ||
echo "on line ${BASH_LINENO[0]}" | ||
exit $error_code | ||
} | ||
trap f ERR | ||
|
||
infile=tests/reads_1.fq | ||
infileidx=tests/tRex1.idx | ||
if [[ -e "${infile}" && -e "${infileidx}" ]]; then | ||
./abismal -v -B -t 2 -i ${infileidx} ${infile} > /dev/null; | ||
else | ||
echo "missing input file(s); skipping test"; | ||
exit 77; | ||
fi | ||
|
||
infile1=tests/reads_pe_1.fq | ||
infile2=tests/reads_pe_2.fq | ||
if [[ -e "${infile1}" && -e "${infile2}" ]]; then | ||
./abismal -v -B -t 2 -i ${infileidx} ${infile1} ${infile2} > /dev/null; | ||
else | ||
echo "missing input file(s); skipping test"; | ||
exit 77; | ||
fi | ||
|
||
infile1=tests/reads_pbat_pe_1.fq | ||
infile2=tests/reads_pbat_pe_2.fq | ||
if [[ -e "${infile1}" && -e "${infile2}" ]]; then | ||
./abismal -v -B -t 2 -P -i ${infileidx} ${infile1} ${infile2} > /dev/null; | ||
else | ||
echo "missing input file(s); skipping tests"; | ||
exit 77; | ||
fi | ||
|
||
infile1=tests/reads_rpbat_pe_1.fq | ||
infile2=tests/reads_rpbat_pe_2.fq | ||
if [[ -e "${infile1}" && -e "${infile2}" ]]; then | ||
./abismal -v -B -t 2 -P -i ${infileidx} ${infile1} ${infile2} > /dev/null; | ||
else | ||
echo "missing input file(s); skipping test"; | ||
exit 77; | ||
fi |