Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
jmmshn committed Apr 22, 2024
1 parent aaebc19 commit 9fbc07b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pymatgen/analysis/defects/supercells.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def get_matched_structure_mapping_old(
uc_struct: Structure,
sc_struct: Structure,
sm: StructureMatcher | None = None,
) -> tuple[NDArray, ArrayLike] | None:
) -> tuple[NDArray, ArrayLike] | None: # pragma: no cover
"""Get the mapping of the supercell to the unit cell.
Get the mapping from the supercell structure onto the base structure,
Expand Down
4 changes: 4 additions & 0 deletions tests/test_supercells.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
get_sc_fromstruct,
get_closest_sc_mat
)
import pytest


def test_supercells(gan_struct):
Expand All @@ -28,6 +29,9 @@ def test_ase_supercells(gan_struct):
sc = gan_struct * sc_mat
assert 4 <= sc.num_sites <= 8

# check raise
with pytest.raises(RuntimeError):
_ase_cubic(gan_struct, min_atoms=4, max_atoms=8, min_length=10)


def test_closest_sc_mat(test_dir):
Expand Down

0 comments on commit 9fbc07b

Please sign in to comment.