Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jbeilstenedmands committed Oct 17, 2024
1 parent 7b18b18 commit 1074204
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tests/regression/test_cluster_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,16 +156,19 @@ def test_rotation_data(dials_data, run_in_tmp_path):
]
result = subprocess.run(args_clustering, capture_output=True)
assert not result.returncode and not result.stderr
check_output(run_in_tmp_path)
assert (run_in_tmp_path / "xia2.cluster_analysis.json").is_file()
assert (run_in_tmp_path / "xia2.cluster_analysis.log").is_file()
assert (run_in_tmp_path / "xia2.cluster_analysis.html").is_file()
assert (run_in_tmp_path / "cc_clusters" / "cluster_2").exists()


def check_output(main_dir, output_clusters=True, interesting_clusters=False):
if output_clusters and not interesting_clusters:
assert (main_dir / "cc_clusters" / "cluster_2").exists()
assert (main_dir / "cos_angle_clusters" / "cluster_2").exists()
if output_clusters and interesting_clusters:
assert (main_dir / "cc_clusters" / "cluster_3").exists()
assert (main_dir / "cos_angle_clusters" / "cluster_3").exists()
assert (main_dir / "cc_clusters" / "cluster_2").exists()
assert (main_dir / "cos_angle_clusters" / "cluster_2").exists()
assert (main_dir / "xia2.cluster_analysis.json").is_file()
assert (main_dir / "xia2.cluster_analysis.log").is_file()
assert (main_dir / "xia2.cluster_analysis.html").is_file()
Expand Down

0 comments on commit 1074204

Please sign in to comment.