Skip to content

Commit c062136

Browse files
committed
test: harden plot_unit_effects against ndim>0 scalar deprecation
Promote the numpy/xarray DeprecationWarning to an error so the regression is caught on all Python versions, not just 3.14.
1 parent fbe8f71 commit c062136

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

causalpy/tests/test_panel_regression.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,9 @@ def test_panel_regression_plot_coefficients(mock_pymc_sample, small_panel_data):
290290

291291

292292
@pytest.mark.integration
293+
@pytest.mark.filterwarnings(
294+
"error:Conversion of an array with ndim > 0 to a scalar:DeprecationWarning"
295+
)
293296
def test_panel_regression_plot_unit_effects(mock_pymc_sample, small_panel_data):
294297
"""Test plot_unit_effects method."""
295298
result = cp.PanelRegression(

0 commit comments

Comments
 (0)