This speeds up running the tests from 210 seconds to 66 seconds on my machine.
This is achieved by introducing a "workdir" fixture that runs the pipeline up to the ready-for-variant-calling BAM file (mapped.calling.bam). The fixture is scoped at module level, that is, it runs only once, allowing us to re-use the already computed parts of the pipeline in some of the slowest tests.
A second change is that the test data is now unpacked into blr-testdata instead of testdata. This is for consistency and to prepare adding a Snakefile under testdata/Snakefile. You may need to adjust your symlinks if you have any, like I do.
Note that the runtime of 16 seconds for test_default_read_mapper is for the setup. That is the first time the workdir fixture is used in the module, so this runs the workdir fixture for the first time.
This speeds up running the tests from 210 seconds to 66 seconds on my machine.
This is achieved by introducing a "workdir" fixture that runs the pipeline up to the ready-for-variant-calling BAM file (
mapped.calling.bam
). The fixture is scoped at module level, that is, it runs only once, allowing us to re-use the already computed parts of the pipeline in some of the slowest tests.A second change is that the test data is now unpacked into
blr-testdata
instead oftestdata
. This is for consistency and to prepare adding aSnakefile
undertestdata/Snakefile
. You may need to adjust your symlinks if you have any, like I do.Before (total 215s):
After (total 67s):
Note that the runtime of 16 seconds for
test_default_read_mapper
is for thesetup
. That is the first time theworkdir
fixture is used in the module, so this runs theworkdir
fixture for the first time.