Skip to content

Commit

Permalink
Update timestamp formatting in markdown export tests to include UTC, …
Browse files Browse the repository at this point in the history
…or raw isoformat in the two different export formats.
  • Loading branch information
dannon committed Dec 10, 2024
1 parent 84ce5e7 commit 5870f7b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions test/unit/app/managers/test_markdown_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ def test_generate_invocation_time(self):
invocation = self._new_invocation()
self.app.workflow_manager.get_invocation.side_effect = [invocation]
result = self._to_basic(example)
expectedtime = invocation.create_time.strftime("%Y-%m-%d, %H:%M:%S")
expectedtime = invocation.create_time.strftime("%Y-%m-%d, %H:%M:%S UTC")
assert f"\n {expectedtime}" in result

def test_job_parameters(self):
Expand Down Expand Up @@ -413,9 +413,7 @@ def test_get_invocation_time(self):
result, extra_data = self._ready_export(example)
assert "invocations" in extra_data
assert "create_time" in extra_data["invocations"]["be8be0fd2ce547f6"]
assert extra_data["invocations"]["be8be0fd2ce547f6"]["create_time"] == invocation.create_time.strftime(
"%Y-%m-%d, %H:%M:%S"
)
assert extra_data["invocations"]["be8be0fd2ce547f6"]["create_time"] == invocation.create_time.isoformat()

def _ready_export(self, example):
return ready_galaxy_markdown_for_export(self.trans, example)

0 comments on commit 5870f7b

Please sign in to comment.