Skip to content

Commit

Permalink
fix the broken test
Browse files Browse the repository at this point in the history
  • Loading branch information
eatyourpeas committed Oct 6, 2024
1 parent f6715f0 commit b66bb5d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions project/npda/tests/kpi_calculations/test_kpi_calculations.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,11 @@ def test_kpi_calculations_dont_break_when_no_patients(AUDIT_START_DATE):
).calculate_kpis_for_patients()

for kpi, results in kpi_calculations_object["calculated_kpi_values"].items():
# remove the kpi_label key from the results
results.pop("kpi_label", None)

values = list(results.values())

assert all(
[isinstance(value, int) or isinstance(value, float) for value in values]
), f"KPI {kpi} has non-integer values: {results}"

0 comments on commit b66bb5d

Please sign in to comment.