From 8ab8a8f7fafa1d26d5455e7bae1749cab0a1d7cd Mon Sep 17 00:00:00 2001 From: Matthias Hochsteger Date: Mon, 9 Sep 2019 17:05:06 +0200 Subject: [PATCH] Test parallel mesh generation --- tests/pytest/test_tutorials.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/pytest/test_tutorials.py b/tests/pytest/test_tutorials.py index 6fabaa60..04c84d34 100644 --- a/tests/pytest/test_tutorials.py +++ b/tests/pytest/test_tutorials.py @@ -70,11 +70,19 @@ def getParamForTest(filename): @pytest.mark.parametrize(("filename, checkFunc"), [getParamForTest(f) for f in _geofiles]) def test_geoFiles(filename, checkFunc): + import filecmp, pyngcore for i, mp in enumerate(getMeshingparameters(filename)): print("load geo", filename) mesh = generateMesh(filename, mp) if checkFunc is not None: checkFunc(mesh,i) + mesh.Save(filename+'_seq.vol.gz') + + with pyngcore.TaskManager(): + mesh_par = generateMesh(filename, mp) + mesh_par.Save(filename+'_par.vol.gz') + + assert filecmp.cmp(filename+'_seq.vol.gz', filename+'_par.vol.gz') import time def generateResultFile():