Skip to content

Commit f4fc159

Browse files
committed
Fix global precision in two test files bleeding to other tests
1 parent f7d962a commit f4fc159

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

tests/compas/files/test_gltf.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from compas.files import GLTFContent
66
from compas.tolerance import TOL
77

8+
# Temporary change the global precision in the TOL class to 12
89
TOL.precision = 12
910

1011
BASE_FOLDER = os.path.dirname(__file__)
@@ -175,3 +176,7 @@ def test_gltf_content():
175176
assert len(node_0.children) == 0
176177
assert len(content.nodes) == 1
177178
assert len(scene.nodes) == 1
179+
180+
181+
# Reset the precision to its default value
182+
TOL.precision = 3

tests/compas/files/test_stl.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from compas.files import STL
66
from compas.tolerance import TOL
77

8+
# Temporary change the global precision in the TOL class to 12
89
TOL.precision = 12
910

1011
BASE_FOLDER = os.path.dirname(__file__)
@@ -43,3 +44,7 @@ def test_binary_read_write_fidelity():
4344
mesh_2 = Mesh.from_stl(fp)
4445
assert mesh.adjacency == mesh_2.adjacency
4546
assert mesh.vertex == mesh_2.vertex
47+
48+
49+
# Reset the precision to its default value
50+
TOL.precision = 3

0 commit comments

Comments
 (0)