better test coverage
This commit is contained in:
parent
8faa5296a1
commit
e0d2859202
|
@ -551,7 +551,7 @@ class Rotation:
|
|||
Parameters
|
||||
----------
|
||||
degrees : bool, optional
|
||||
Return angles in degrees.
|
||||
Return angles in degrees. Defaults to False.
|
||||
|
||||
Returns
|
||||
-------
|
||||
|
|
|
@ -150,10 +150,12 @@ class TestOrientation:
|
|||
== np.eye(3))
|
||||
|
||||
def test_from_fiber_component(self):
|
||||
r = Rotation.from_fiber_component(crystal=np.zeros(2),sample=np.zeros(2),
|
||||
crystal = np.random.rand(2) * [180,360]
|
||||
sample = np.random.rand(2) * [180,360]
|
||||
r = Rotation.from_fiber_component(crystal=crystal,sample=sample,
|
||||
sigma=0.0,shape=1,rng_seed=0)
|
||||
assert np.all(Orientation.from_fiber_component(crystal=np.zeros(2),sample=np.zeros(2),
|
||||
sigma=0.0,shape=None,rng_seed=0,family='triclinic').quaternion
|
||||
assert np.all(Orientation.from_fiber_component(crystal=crystal,sample=sample,
|
||||
sigma=0.0,shape=None,rng_seed=0,lattice='cI').quaternion
|
||||
== r.quaternion)
|
||||
|
||||
@pytest.mark.parametrize('kwargs',[
|
||||
|
|
Loading…
Reference in New Issue