katholt / srst2

Short Read Sequence Typing for Bacterial Pathogens
Other
123 stars 65 forks source link

Get samtools and bowtie executables from env variables (with tests) #51

Closed bewt85 closed 8 years ago

bewt85 commented 8 years ago

This is an alternative to https://github.com/katholt/srst2/pull/50 which also adds tests. These can be invoked as follows and require the mock module (i.e. pip install mock).

python -m unittest discover tests/

As discussed in https://github.com/katholt/srst2/issues/49 this PR allows you to specify the path to your samtools or bowtie executables using an environment variable. This is useful if you've got multiple versions of samtools installed on your cluster (for example).

I've tested the changes by running https://github.com/katholt/srst2/blob/master/example.txt; the output was https://gist.github.com/bewt85/70af411d276c22a53d8d

The behaviour is as follows:

Let me know if you've got any questions.

Ben