tests/biobambam2: convert to new stand-alone test process (#35696)
This commit is contained in:
parent
d85a27f317
commit
212b1edb6b
@ -30,25 +30,16 @@ def configure_args(self):
|
||||
args = ["--with-libmaus2={0}".format(self.spec["libmaus2"].prefix)]
|
||||
return args
|
||||
|
||||
def _fix_shortsort(self):
|
||||
"""Fix the testshortsort.sh file copied during installation."""
|
||||
test_dir = join_path(self.install_test_root, self.test_src_dir)
|
||||
filter_file("../src/", "", join_path(test_dir, "testshortsort.sh"))
|
||||
|
||||
@run_after("install")
|
||||
def cache_test_sources(self):
|
||||
"""Copy the test source files after the package is installed to an
|
||||
install test subdirectory for use during `spack test run`."""
|
||||
self.cache_extra_test_sources(self.test_src_dir)
|
||||
self._fix_shortsort()
|
||||
|
||||
def test(self):
|
||||
"""Perform stand-alone/smoke test on installed package."""
|
||||
def test_short_sort(self):
|
||||
"""run testshortsort.sh to check alignments sorted by coordinate"""
|
||||
test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir)
|
||||
self.run_test(
|
||||
"sh",
|
||||
["testshortsort.sh"],
|
||||
expected="Alignments sorted by coordinate.",
|
||||
purpose="test: checking alignments",
|
||||
work_dir=test_dir,
|
||||
)
|
||||
with working_dir(test_dir):
|
||||
sh = which("sh")
|
||||
out = sh("testshortsort.sh", output=str.split, error=str.split)
|
||||
assert "Alignments sorted by coordinate." in out
|
||||
|
Loading…
Reference in New Issue
Block a user