checking for invalid volume fractions
This commit is contained in:
parent
aa11e1aca3
commit
7420c779d7
|
@ -167,6 +167,11 @@ class TestConfigMaterial:
|
||||||
with pytest.raises(ValueError):
|
with pytest.raises(ValueError):
|
||||||
ConfigMaterial().material_add(**kw)
|
ConfigMaterial().material_add(**kw)
|
||||||
|
|
||||||
|
@pytest.mark.parametrize('v',[2,np.ones(3)*2,np.ones((2,2))])
|
||||||
|
def test_material_add_invalid_v(self,v):
|
||||||
|
with pytest.raises(ValueError):
|
||||||
|
ConfigMaterial().material_add(v=v)
|
||||||
|
|
||||||
@pytest.mark.parametrize('cell_ensemble_data',[None,'CellEnsembleData'])
|
@pytest.mark.parametrize('cell_ensemble_data',[None,'CellEnsembleData'])
|
||||||
def test_load_DREAM3D(self,ref_path,cell_ensemble_data):
|
def test_load_DREAM3D(self,ref_path,cell_ensemble_data):
|
||||||
grain_c = ConfigMaterial.load_DREAM3D(ref_path/'2phase_irregularGrid.dream3d','Grain Data',
|
grain_c = ConfigMaterial.load_DREAM3D(ref_path/'2phase_irregularGrid.dream3d','Grain Data',
|
||||||
|
|
Loading…
Reference in New Issue