Skip to content

Commit

Permalink
Just one more make_hpge() test
Browse files Browse the repository at this point in the history
  • Loading branch information
gipert authored and ManuelHu committed Dec 10, 2024
1 parent c7f2420 commit 3b79e40
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/legendhpges/v02160a.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ class V02160A(HPGe):
Note
----
The center of the cut plane faces the positive x-direction with a certain angle with respect to xz-plane.
The center of the cut plane faces the positive x-direction with a
certain angle with respect to xz-plane.
"""

def _g4_solid(self):
Expand Down
12 changes: 11 additions & 1 deletion tests/test_det_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ def test_make_p00664b(reg_or_none):
gedet = make_hpge(
configs.P00664B,
name="P00664B_bis",
allow_cylindrical_asymmetry=False,
registry=reg_or_none,
allow_cylindrical_asymmetry=False,
)
assert isinstance(gedet, PPC)
assert not isinstance(gedet, P00664B)
Expand All @@ -149,6 +149,16 @@ def test_make_v02160a(reg_or_none):

assert len(gedet._decode_polycone_coord()[0]) == len(gedet.surfaces) + 1

gedet = make_hpge(
configs.V02160A,
name="V02160A_bis",
registry=reg_or_none,
allow_cylindrical_asymmetry=False,
)
assert isinstance(gedet, InvertedCoax)
assert not isinstance(gedet, V02160A)
assert isinstance(gedet.solid, geant4.solid.GenericPolycone)


def test_null_enrichment(reg_or_none):
metadata = configs.V07646A
Expand Down

0 comments on commit 3b79e40

Please sign in to comment.