Fill test coverage gaps and fix polyhedra_from_atom_indices bug#16
Open
Fill test coverage gaps and fix polyhedra_from_atom_indices bug#16
Conversation
Add 42 behavioural tests across all major modules, covering previously untested methods and edge cases: - utils: prune_neighbour_list, lattice_mc_string - orientation_parameters: projection_xyz, oct_rotational_order_parameter - CoordinationPolyhedron: label/set_label, equal_vertices, __eq__, best_fit_geometry, volume, edge_graph, faces, minimum_image_vertex_coordinates, intersection, neighbours - PolyhedraRecipe: polyhedra_from_nearest_neighbours, polyhedra_from_closest_centre, polyhedra_from_atom_indices, end-to-end find_polyhedra for nearest neighbours and closest centre - Configuration: polyhedra_by_label with list, face_sharing_neighbour_list, to_lattice_mc - Trajectory: from_structures, __add__ New tests prefer real pymatgen objects over mocks where practical. Fix variable shadowing bug in polyhedra_from_atom_indices where the loop variable overwrote the vertex_atoms parameter, causing only the first polyhedron to receive correct vertices (see #15).
…e_cutoff Address code review feedback on PR #16: - Test callable, list[int], and invalid-type branches of generator_from_atom_argument - Add behavioural test for polyhedra_from_distance_cutoff with real atoms verifying cutoff filtering - Add regression docstring on test_correct_assignment_from_explicit_indices linking to issue #15
Patch release for the polyhedra_from_atom_indices bugfix (#15).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
polyhedra_from_atom_indiceswhere the loop variable overwrote thevertex_atomsparameter, causing only the first polyhedron to receive correct vertices (fixes Bug: polyhedra_from_atom_indices shadows vertex_atoms parameter in loop #15)