Skip to content

Commit

Permalink
refactor: make test robust against floating point
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrugman committed Jul 4, 2022
1 parent fbf7e41 commit 41ea553
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/popmon/base/test_pipeline.py
Expand Up @@ -98,7 +98,9 @@ def test_popmon_pipeline(test_pipeline):
np.power(np.log(datastore["x"]), 2) * datastore["weights"]
) / np.sum(datastore["weights"])

assert test_pipeline.transform(datastore)["res"] == expected_result
np.testing.assert_array_almost_equal(
test_pipeline.transform(datastore)["res"], expected_result, decimal=12
)


def test_pipeline_repr(test_pipeline):
Expand Down

0 comments on commit 41ea553

Please sign in to comment.