diff --git a/Tests/Python/test_simulator_mesh_interface.py b/Tests/Python/test_simulator_mesh_interface.py index 2221300c65a8d7c6b3d6d3e13532da91e3eb51d6..61ca3fa73f71b3f386a9985ef33eef442dcfc217 100644 --- a/Tests/Python/test_simulator_mesh_interface.py +++ b/Tests/Python/test_simulator_mesh_interface.py @@ -1,6 +1,6 @@ -import os import sys import tempfile +from pathlib import Path import numpy as np import ogs.mesh as mesh # noqa: F401 @@ -79,9 +79,10 @@ def checkCells(cells, celltypes, points): def test_simulator(): + current_dir = Path(__file__).parent.abspath() arguments = [ "", - f"{os.path.abspath(os.path.dirname(__file__))}/../Data/Parabolic/LiquidFlow/Flux/3D/Hex/cuboid_1x1x1_hex_27_Dirichlet_Dirichlet_Python.prj", + f"{current_dir}/../Data/Parabolic/LiquidFlow/Flux/3D/Hex/cuboid_1x1x1_hex_27_Dirichlet_Dirichlet_Python.prj", "-o " + tempfile.mkdtemp(), ]