@@ -33,15 +33,37 @@ def cleaning_fxns(get_registry):
33
33
return CleaningTools (get_registry )
34
34
35
35
36
+ def test_standard_cleaning (path_to_cif , cleaning_fxns ):
37
+ result = cleaning_fxns ._standard_cleaning (path_to_cif )
38
+ path_to_cleaned_file = "tidy_" + path_to_cif
39
+ os .remove (path_to_cleaned_file )
40
+ msg = f"Cleaned File. Standard cleaning. Written to { path_to_cleaned_file } "
41
+ assert msg == result
42
+
43
+
44
+ def test_remove_water (path_to_cif , cleaning_fxns ):
45
+ result = cleaning_fxns ._remove_water (path_to_cif )
46
+ path_to_cleaned_file = "tidy_" + path_to_cif
47
+ os .remove (path_to_cleaned_file )
48
+ msg = f"Cleaned File. Removed water. Written to { path_to_cleaned_file } "
49
+ assert msg == result
50
+
51
+
36
52
def test_add_hydrogens_and_remove_water (path_to_cif , cleaning_fxns ):
37
53
result = cleaning_fxns ._add_hydrogens_and_remove_water (path_to_cif )
38
54
path_to_cleaned_file = "tidy_" + path_to_cif
39
55
os .remove (path_to_cleaned_file )
40
- assert "Cleaned File" in result
56
+ msg = (
57
+ f"Cleaned File. Missing Hydrogens "
58
+ f"added and water removed. Written to "
59
+ f"{ path_to_cleaned_file } "
60
+ )
61
+ assert msg == result
41
62
42
63
43
- def test_standard_cleaning (path_to_cif , cleaning_fxns ):
44
- result = cleaning_fxns ._standard_cleaning (path_to_cif )
64
+ def test_add_hyrogens (path_to_cif , cleaning_fxns ):
65
+ result = cleaning_fxns ._add_hydrogens (path_to_cif )
45
66
path_to_cleaned_file = "tidy_" + path_to_cif
46
67
os .remove (path_to_cleaned_file )
47
- assert "Cleaned File" in result
68
+ msg = f"Cleaned File. Missing Hydrogens added. Written to { path_to_cleaned_file } "
69
+ assert msg == result
0 commit comments