From a6eb836ade803070952e8ee61e0b172c639a545c Mon Sep 17 00:00:00 2001 From: "@jmmshn" Date: Tue, 21 May 2024 15:29:21 -0700 Subject: [PATCH] lint --- tests/test_corrections.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/test_corrections.py b/tests/test_corrections.py index e3c2db71..7578556c 100644 --- a/tests/test_corrections.py +++ b/tests/test_corrections.py @@ -3,7 +3,10 @@ get_freysoldt_correction, plot_plnr_avg, ) -from pymatgen.analysis.defects.corrections.kumagai import get_efnv_correction, get_structure_with_pot +from pymatgen.analysis.defects.corrections.kumagai import ( + get_efnv_correction, + get_structure_with_pot, +) def test_freysoldt(data_Mg_Ga) -> None: @@ -87,8 +90,10 @@ def test_kumagai(test_dir): ) assert res1.correction_energy > 0 + def test_kumagai_missing(): from pymatgen.analysis.defects.corrections import kumagai + kumagai.__has_pydefect__ = False with pytest.raises(ImportError): kumagai._check_import_pydefect()