summaryrefslogtreecommitdiff
path: root/src/python/test/test_simplex_tree.py
diff options
context:
space:
mode:
authorROUVREAU Vincent <vincent.rouvreau@inria.fr>2020-12-11 10:31:09 +0100
committerROUVREAU Vincent <vincent.rouvreau@inria.fr>2020-12-11 10:31:09 +0100
commit40e0976e8dae27f0e30f3c9df1fd7de1a7343948 (patch)
tree6c92c66582ef43eeadc64b4e217f99463b5e802f /src/python/test/test_simplex_tree.py
parent957da77f9484972ce34d0415502887f92080878e (diff)
code review: throw an eception if collapse_edges when no Eigen3
Diffstat (limited to 'src/python/test/test_simplex_tree.py')
-rwxr-xr-xsrc/python/test/test_simplex_tree.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/python/test/test_simplex_tree.py b/src/python/test/test_simplex_tree.py
index 0c072baa..a3eacaa9 100755
--- a/src/python/test/test_simplex_tree.py
+++ b/src/python/test/test_simplex_tree.py
@@ -353,15 +353,16 @@ def test_collapse_edges():
assert st.num_simplices() == 10
- # If no Eigen3, collapse_edges just return a copy, no action. Maybe it would require some user warning
- st.collapse_edges()
if __GUDHI_USE_EIGEN3:
+ st.collapse_edges()
assert st.num_simplices() == 9
assert st.find([1, 3]) == False
for simplex in st.get_skeleton(0):
assert simplex[1] == 1.
else:
- assert st.num_simplices() == 10
+ # If no Eigen3, collapse_edges throws an exception
+ with pytest.raises(RuntimeError):
+ st.collapse_edges()
def test_reset_filtration():
st = SimplexTree()