@@ -767,27 +767,25 @@ def test_geometry_touching_intersections_plane(x0):
767
767
768
768
769
769
def test_pop_axis ():
770
- b = td .Box (size = (1 , 1 , 1 ))
771
770
for axis in range (3 ):
772
771
coords = (1 , 2 , 3 )
773
- Lz , (Lx , Ly ) = b .pop_axis (coords , axis = axis )
774
- _coords = b .unpop_axis (Lz , (Lx , Ly ), axis = axis )
772
+ Lz , (Lx , Ly ) = td . Box .pop_axis (coords , axis = axis )
773
+ _coords = td . Box .unpop_axis (Lz , (Lx , Ly ), axis = axis )
775
774
assert all (c == _c for (c , _c ) in zip (coords , _coords ))
776
- _Lz , (_Lx , _Ly ) = b .pop_axis (_coords , axis = axis )
775
+ _Lz , (_Lx , _Ly ) = td . Box .pop_axis (_coords , axis = axis )
777
776
assert Lz == _Lz
778
777
assert Lx == _Lx
779
778
assert Ly == _Ly
780
779
781
780
782
781
@pytest .mark .parametrize ("transpose" , [True , False ])
783
782
def test_pop_axis_and_swap (transpose ):
784
- b = td .Box (size = (1 , 1 , 1 ))
785
783
for axis in range (3 ):
786
784
coords = (1 , 2 , 3 )
787
- Lz , (Lx , Ly ) = b .pop_axis_and_swap (coords , axis = axis , transpose = transpose )
788
- _coords = b .unpop_axis_and_swap (Lz , (Lx , Ly ), axis = axis , transpose = transpose )
785
+ Lz , (Lx , Ly ) = td . Box .pop_axis_and_swap (coords , axis = axis , transpose = transpose )
786
+ _coords = td . Box .unpop_axis_and_swap (Lz , (Lx , Ly ), axis = axis , transpose = transpose )
789
787
assert all (c == _c for (c , _c ) in zip (coords , _coords ))
790
- _Lz , (_Lx , _Ly ) = b .pop_axis_and_swap (_coords , axis = axis , transpose = transpose )
788
+ _Lz , (_Lx , _Ly ) = td . Box .pop_axis_and_swap (_coords , axis = axis , transpose = transpose )
791
789
assert Lz == _Lz
792
790
assert Lx == _Lx
793
791
assert Ly == _Ly
0 commit comments