Skip to content

Commit e5dedcb

Browse files
Bump test tooling versions, and fix poly unit tests.
1 parent 874990c commit e5dedcb

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

pyproject.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ include = [
7272
dependencies = [
7373
'formulaic[arrow,calculus]; python_version < "3.11"',
7474
'formulaic[calculus]; python_version == "3.11"',
75-
"pytest==6.2.5",
76-
"pytest-cov==3.0.0",
75+
"pytest==7.2.0",
76+
"pytest-cov==4.0.0",
7777
]
7878

7979
[tool.hatch.envs.default.scripts]
@@ -88,8 +88,8 @@ python = ["37"]
8888
[tool.hatch.envs.test_min]
8989
dependencies = [
9090
"formulaic[arrow,calculus]",
91-
"pytest==6.2.5",
92-
"pytest-cov==3.0.0",
91+
"pytest==7.2.0",
92+
"pytest-cov==4.0.0",
9393
"astor==0.8",
9494
"cached-property==1.3.0; python_version < \"3.8\"",
9595
"graphlib-backport==1.0.0; python_version < \"3.9\"",

tests/transforms/test_poly.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ def test_basic(self, data):
4747
r_reference,
4848
)
4949

50-
assert pytest.approx(state["alpha"], {0: 0.5})
51-
assert pytest.approx(state["norms2"], {0: 21.0, 2: 1.925})
50+
assert state["alpha"] == pytest.approx({0: 0.5})
51+
assert state["norms2"] == pytest.approx({0: 21.0, 1: 1.925})
5252

5353
assert numpy.allclose(
5454
poly(data, _state=state)[:, 0],
@@ -95,9 +95,9 @@ def test_degree(self, data):
9595
r_reference,
9696
)
9797

98-
assert pytest.approx(state["alpha"], {0: 0.5, 1: 0.5, 2: 0.5})
99-
assert pytest.approx(
100-
state["norms2"], {1: 0.09166666666666667, 2: 0.07283333333333333}
98+
assert state["alpha"] == pytest.approx({0: 0.5, 1: 0.5, 2: 0.5})
99+
assert state["norms2"] == pytest.approx(
100+
{0: 21.0, 1: 1.925, 2: 0.14020416666666669, 3: 0.009734175}
101101
)
102102

103103
assert numpy.allclose(

0 commit comments

Comments
 (0)