Skip to content

Commit

Permalink
Add test for audit info in runs.tabulate()
Browse files Browse the repository at this point in the history
  • Loading branch information
danielhuppmann committed Oct 24, 2024
1 parent 223f23e commit a5132db
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/core/test_run.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,12 @@ def test_run_versions(self, platform: ixmp4.Platform):
pd.DataFrame(_expected_runs_table(True, False)),
)

# using audit_info=True shows additional columns
audit_info = platform.runs.tabulate(default_only=False, audit_info=True)
for column in ["updated_at", "updated_by", "created_at", "created_by", "id"]:
assert column in audit_info.columns
pdt.assert_series_equal(audit_info.id, pd.Series([run1.id, run2.id], name="id"))

# default version can be retrieved directly
run = platform.runs.get("Model", "Scenario")
assert run1.id == run.id
Expand Down

0 comments on commit a5132db

Please sign in to comment.