diff options
author | ROUVREAU Vincent <vincent.rouvreau@inria.fr> | 2020-02-12 10:24:25 +0100 |
---|---|---|
committer | ROUVREAU Vincent <vincent.rouvreau@inria.fr> | 2020-02-12 10:24:25 +0100 |
commit | 73ad191a7dee054a58e9823c84dce9f1e71995f4 (patch) | |
tree | d3ffa37354694a06332470916924e6e990201b9b /src/python/test/test_cubical_complex.py | |
parent | 2eb23726256af164282830b21561b11db9bdde39 (diff) |
Fix tests according to exception management
Diffstat (limited to 'src/python/test/test_cubical_complex.py')
-rwxr-xr-x | src/python/test/test_cubical_complex.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/python/test/test_cubical_complex.py b/src/python/test/test_cubical_complex.py index 8c1b2600..fce4875c 100755 --- a/src/python/test/test_cubical_complex.py +++ b/src/python/test/test_cubical_complex.py @@ -10,6 +10,7 @@ from gudhi import CubicalComplex, PeriodicCubicalComplex import numpy as np +import pytest __author__ = "Vincent Rouvreau" __copyright__ = "Copyright (C) 2016 Inria" @@ -25,9 +26,8 @@ def test_empty_constructor(): def test_non_existing_perseus_file_constructor(): # Try to open a non existing file - cub = CubicalComplex(perseus_file="pouetpouettralala.toubiloubabdou") - assert cub.__is_defined() == False - assert cub.__is_persistence_defined() == False + with pytest.raises(FileNotFoundError): + cub = CubicalComplex(perseus_file="pouetpouettralala.toubiloubabdou") def test_dimension_or_perseus_file_constructor(): |