Skip to content

Commit

Permalink
re error?
Browse files Browse the repository at this point in the history
  • Loading branch information
petrelharp committed Jul 7, 2024
1 parent 8ca742c commit a087382
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions tests/test_slim_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,13 @@ def test_recap_and_rescale_on_external_slim_run(self, tmp_path):
slim_scaling_factor=10,
seed=seed,
)
out = re.sub(
r'defineConstant\("trees_file.+;',
rf'defineConstant("trees_file", "{treefile}");',
out,
)
a, b = re.split(r'defineConstant\("trees_file.+;', out)
out = a + 'defineConstant("trees_file", ' + str(treefile) + ");" + b
# out = re.sub(
# r'defineConstant\("trees_file.+;',
# rf'defineConstant("trees_file", "{treefile}");',
# out,
# )
with open(scriptfile, "w") as f:
f.write(out)
engine._run_slim(scriptfile, seed=seed)
Expand Down

0 comments on commit a087382

Please sign in to comment.