Skip to content
Snippets Groups Projects

Notebook unit testing

1 file
+ 2
2
Compare changes
  • Side-by-side
  • Inline
+ 2
2
@@ -28,7 +28,7 @@ def test_load_type_memmap():
def test_invalid_path():
invalid_path = os.path.join("this", "path", "doesnt", "exist.tif")
with pytest.raises(ValueError):
with pytest.raises(FileNotFoundError):
qim3d.io.load(invalid_path)
@@ -36,5 +36,5 @@ def test_did_you_mean():
# Remove last two characters from the path
path_misspelled = str(volume_path)[:-2]
with pytest.raises(ValueError, match=re.escape(repr(str(volume_path)))):
with pytest.raises(FileNotFoundError, match=re.escape(repr(str(volume_path)))):
qim3d.io.load(path_misspelled)
Loading