From 894f8393e01ef61cf455be1677d6e11a33b9b1cb Mon Sep 17 00:00:00 2001 From: German <28149841+germa89@users.noreply.github.com> Date: Fri, 20 Sep 2024 21:21:41 +0200 Subject: [PATCH] fix: test and adding test for quality --- tests/test_plotting.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/tests/test_plotting.py b/tests/test_plotting.py index c67e784c73..d8b48ea447 100644 --- a/tests/test_plotting.py +++ b/tests/test_plotting.py @@ -255,7 +255,7 @@ def test_aplot(cleared, mapdl, vtk): mapdl.aplot(show_area_numbering=True) mapdl.aplot(vtk=vtk, color_areas=vtk, show_lines=True, show_line_numbering=True) - mapdl.aplot(quality=100) + mapdl.aplot(quality=10) mapdl.aplot(quality=-1) @@ -1243,3 +1243,12 @@ def test_xplot_not_changing_geo_selection_components( plot_func = getattr(mapdl, plot_func) check_geometry(mapdl, plot_func) + + +@pytest.mark.parametrize("quality", [101, -2, 0, "as"]) +def test_aplot_quality_fail(mapdl, block, quality): + with pytest.raises( + ValueError, + match="The argument 'quality' can only be a integer between 1 and 10 (included both)", + ): + mapdl.aplot(quality=quality)