Skip to content
Snippets Groups Projects
Commit 607a75d2 authored by Reinhard Prix's avatar Reinhard Prix
Browse files

fix check_cached_data_okay_to_use()

- logged commandline can contain full path to exectable, so
  cmdline-comparison must be agnostic to that
- fixes failing test against pip-installed lalsuite
parent d569dc90
No related branches found
No related tags found
1 merge request!22Gitlab ci runner setup
...@@ -284,8 +284,8 @@ transientTau = {:10.0f}\n""" ...@@ -284,8 +284,8 @@ transientTau = {:10.0f}\n"""
logging.info("Checking contents of cff file") logging.info("Checking contents of cff file")
cl_dump = "lalapps_SFTdumpheader {} | head -n 20".format(self.sftfilepath) cl_dump = "lalapps_SFTdumpheader {} | head -n 20".format(self.sftfilepath)
output = helper_functions.run_commandline(cl_dump) output = helper_functions.run_commandline(cl_dump)
calls = [line for line in output.split("\n") if line[:3] == "lal"] found = [True for line in output.split("\n") if line[-len(cl_mfd) :] == cl_mfd]
if calls[0] == cl_mfd: if any(found):
logging.info("Contents matched, use old sft file") logging.info("Contents matched, use old sft file")
return True return True
else: else:
......
...@@ -7,6 +7,7 @@ import lalpulsar ...@@ -7,6 +7,7 @@ import lalpulsar
import logging import logging
import time import time
class Test(unittest.TestCase): class Test(unittest.TestCase):
outdir = "TestData" outdir = "TestData"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment