Skip to content

Commit

Permalink
Add dependency in restart test case
Browse files Browse the repository at this point in the history
Because we don't know the filename of the restart file at
setup time, we need to instead make the `full_run` step an
explicit dependency of the `restart_run` step.
  • Loading branch information
xylar committed Jul 25, 2023
1 parent 1dbfcc4 commit 4f53281
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions polaris/ocean/tests/baroclinic_channel/restart/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,14 @@ def __init__(self, test_group, resolution):
super().__init__(test_group=test_group, resolution=resolution,
name='restart')

for name in ['full_run', 'restart_run']:
self.add_step(
RestartStep(test_case=self, resolution=resolution,
name=name))
full = RestartStep(test_case=self, resolution=resolution,
name='full_run')
self.add_step(full)

restart = RestartStep(test_case=self, resolution=resolution,
name='restart_run')
restart.add_dependency(full, full.name)
self.add_step(restart)

def validate(self):
"""
Expand Down

0 comments on commit 4f53281

Please sign in to comment.