| 1 | #!/bin/bash |
| 2 | |
| 3 | #set -x |
| 4 | |
| 5 | NAME="read name length" |
| 6 | BIN="ngmlr-"`grep -o "set( NGM_VERSION_MAJOR [0-9]* )" CMakeLists.txt | cut -d " " -f 3`"."`grep -o "set( NGM_VERSION_MINOR [0-9]* )" CMakeLists.txt | cut -d " " -f 3`"."`grep -o "set( NGM_VERSION_BUILD [^ ]* )" CMakeLists.txt | grep -v debug | cut -d " " -f 3` |
| 7 | PARAMETER=" --skip-write " |
| 8 | |
| 9 | echo "Test: $NAME ($BIN)" |
| 10 | |
| 11 | bin/${BIN}/ngmlr $PARAMETER -r test/data/test_1/ref_chr6_140kb.fa -q test/data/test_1/long_name.fa 2> /dev/null | grep -v "^@" | cut -f 1 > test/data/test_1/found.txt |
| 12 | |
| 13 | diff test/data/test_1/expected.txt test/data/test_1/found.txt && echo "Success" |
| 14 | |
| 15 | rm test/data/test_1/found.txt |