diff --git a/CHANGELOG.md b/CHANGELOG.md index 6597b85..bcf3b11 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,7 +21,8 @@ ### Enhancements - Add python 3.13 to list of supported versions ([#158](https://github.com/mpytools/mplotutils/pull/158)). -- Increased test coverage ([#180](https://github.com/mpytools/mplotutils/pull/180), and [#181](https://github.com/mpytools/mplotutils/pull/181)). +- Increased test coverage ([#180](https://github.com/mpytools/mplotutils/pull/180), [#181](https://github.com/mpytools/mplotutils/pull/181), + and [#182](https://github.com/mpytools/mplotutils/pull/182)). ### Bug fixes diff --git a/mplotutils/tests/test_set_map_layout_axes_grid.py b/mplotutils/tests/test_set_map_layout_axes_grid.py index 774aa5b..fe85f3d 100644 --- a/mplotutils/tests/test_set_map_layout_axes_grid.py +++ b/mplotutils/tests/test_set_map_layout_axes_grid.py @@ -7,6 +7,22 @@ from . import figure_context, get_rtol +def test_set_map_layout_error_ncol_nrow(): + with figure_context() as f: + + axgr = AxesGrid(f, 111, nrows_ncols=(1, 1)) + + msg = "Cannot pass 'nrow' or 'ncol' for and 'AxesGrid'" + with pytest.raises(TypeError, match=msg): + set_map_layout(axgr, ncol=1) + + with pytest.raises(TypeError, match=msg): + set_map_layout(axgr, nrow=1) + + with pytest.raises(TypeError, match=msg): + set_map_layout(axgr, nrow=1, ncol=1) + + def test_set_map_layout_default_width(): with figure_context() as f: