def test_configure(self): """ Test _configure(). """ fault = FaultCohesiveDyn() fault.inventory.faultLabel = "fault group" fault._configure() return
def test_configure(self): """ Test _configure(). """ fault = FaultCohesiveDyn() fault.inventory.faultLabel = "fault group" fault._configure() return
def test_adjustTopology(self): """ Test adjustTopology(). WARNING: This is not a rigorous test of adjustTopology() because we neither set the input fields or verify the results. """ cs = CSCart() cs.inventory.spaceDim = 2 cs._configure() from spatialdata.units.Nondimensional import Nondimensional normalizer = Nondimensional() normalizer._configure() from pylith.meshio.MeshIOAscii import MeshIOAscii importer = MeshIOAscii() importer.inventory.filename = "data/tri3.mesh" importer.inventory.coordsys = cs importer._configure() mesh = importer.read(debug=False, interpolate=False) fault = FaultCohesiveDyn() fault.inventory.matId = 10 fault.inventory.faultLabel = "fault" fault._configure() nvertices = fault.numVerticesNoMesh(mesh) firstFaultVertex = 0 firstLagrangeVertex = nvertices firstFaultCell = 2*nvertices fault.adjustTopology(mesh, firstFaultVertex, firstLagrangeVertex, firstFaultCell) # We should really add something here to check to make sure things # actually initialized correctly return
def test_adjustTopology(self): """ Test adjustTopology(). WARNING: This is not a rigorous test of adjustTopology() because we neither set the input fields or verify the results. """ cs = CSCart() cs.inventory.spaceDim = 2 cs._configure() from spatialdata.units.Nondimensional import Nondimensional normalizer = Nondimensional() normalizer._configure() from pylith.meshio.MeshIOAscii import MeshIOAscii importer = MeshIOAscii() importer.inventory.filename = "data/tri3.mesh" importer.inventory.coordsys = cs importer._configure() mesh = importer.read(debug=False, interpolate=False) fault = FaultCohesiveDyn() fault.inventory.matId = 10 fault.inventory.faultLabel = "fault" fault._configure() nvertices = fault.numVerticesNoMesh(mesh) firstFaultVertex = 0 firstLagrangeVertex = nvertices firstFaultCell = 2 * nvertices fault.adjustTopology(mesh, firstFaultVertex, firstLagrangeVertex, firstFaultCell) # We should really add something here to check to make sure things # actually initialized correctly return