FEM: ccx unit tests, add material nonlinear input file writing test

This commit is contained in:
Bernd Hahnebach
2018-02-23 23:47:31 +01:00
parent ef02f53f5d
commit bcb7d3cdc4
4 changed files with 20183 additions and 12 deletions

View File

@@ -176,6 +176,7 @@ SET(FemTestsCcx_SRCS
femtest/data/ccx/cube_static_expected_values
femtest/data/ccx/cube_static.FCStd
femtest/data/ccx/cube.FCStd
femtest/data/ccx/mat_nonlinear.inp
femtest/data/ccx/multimat.inp
femtest/data/ccx/spine_thermomech.inp
femtest/data/ccx/spine_thermomech.dat

View File

@@ -125,10 +125,11 @@ gf()
./bin/FreeCADCmd --run-test "femtest.app.test_femimport.TestObjectExistance.test_objects_existance"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_1_static_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_2_static_multiple_material"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_3_freq_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_4_thermomech_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_5_Flow1D_thermomech_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_6_contact_shell_shell"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_3_static_material_nonlinar"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_4_freq_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_5_thermomech_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_6_Flow1D_thermomech_analysis"
./bin/FreeCADCmd --run-test "femtest.app.test_ccxtools.TestCcxTools.test_7_contact_shell_shell"
./bin/FreeCADCmd --run-test "femtest.app.test_common.TestFemCommon.test_adding_refshaps"
./bin/FreeCADCmd --run-test "femtest.app.test_common.TestFemCommon.test_pyimport_all_FEM_modules"
./bin/FreeCADCmd --run-test "femtest.app.test_material.TestMaterialUnits.test_known_quantity_units"
@@ -170,16 +171,19 @@ import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_2_static_multiple_material"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_3_freq_analysis"))
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_3_static_material_nonlinar"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_4_thermomech_analysis"))
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_4_freq_analysis"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_5_Flow1D_thermomech_analysis"))
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_5_thermomech_analysis"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_6_contact_shell_shell"))
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_6_Flow1D_thermomech_analysis"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_ccxtools.TestCcxTools.test_7_contact_shell_shell"))
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.app.test_common.TestFemCommon.test_adding_refshaps"))

View File

@@ -123,7 +123,28 @@ class TestCcxTools(unittest.TestCase):
)
# ********************************************************************************************
def test_3_freq_analysis(
def test_3_static_material_nonlinar(
self
):
# set up
from femexamples.material_nl_platewithhole import setup
setup(self.active_doc, "ccxtools")
test_name = "nonlinear material test"
base_name = "mat_nonlinear"
analysis_dir = testtools.get_unit_test_tmp_dir(
self.temp_dir,
"FEM_ccx_matnonlinear"
)
# test input file writing
self.input_file_writing_test(
test_name=test_name,
base_name=base_name,
analysis_dir=analysis_dir,
)
# ********************************************************************************************
def test_4_freq_analysis(
self
):
# set up
@@ -156,7 +177,7 @@ class TestCcxTools(unittest.TestCase):
)
# ********************************************************************************************
def test_4_thermomech_analysis(
def test_5_thermomech_analysis(
self
):
# set up
@@ -189,7 +210,7 @@ class TestCcxTools(unittest.TestCase):
)
# ********************************************************************************************
def test_5_Flow1D_thermomech_analysis(
def test_6_Flow1D_thermomech_analysis(
self
):
# set up
@@ -222,7 +243,7 @@ class TestCcxTools(unittest.TestCase):
)
# ********************************************************************************************
def test_6_contact_shell_shell(
def test_7_contact_shell_shell(
self
):
# set up

File diff suppressed because it is too large Load Diff