forked from dlubal-software/RSTAB_Python_Client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest_timberEffectiveLengths.py
More file actions
38 lines (30 loc) · 1.5 KB
/
Copy pathtest_timberEffectiveLengths.py
File metadata and controls
38 lines (30 loc) · 1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import sys
import os
PROJECT_ROOT = os.path.abspath(os.path.join(
os.path.dirname(__file__),
os.pardir)
)
sys.path.append(PROJECT_ROOT)
from RSTAB.enums import *
from RSTAB.initModel import Model, SetAddonStatus
from RSTAB.TypesForTimberDesign.timberEffectiveLengths import TimberEffectiveLengths
if Model.clientModel is None:
Model()
def test_timberEffectiveLengths():
Model.clientModel.service.delete_all()
Model.clientModel.service.begin_modification()
SetAddonStatus(Model.clientModel, AddOn.timber_design_active, True)
TimberEffectiveLengths()
Model.clientModel.service.finish_modification()
tel = Model.clientModel.service.get_timber_effective_lengths(1)
assert tel.flexural_buckling_about_y == True
assert tel.flexural_buckling_about_z == True
assert tel.intermediate_nodes == False
assert tel.different_properties == True
assert tel.factors_definition_absolute == False
assert tel.fire_design_different_buckling_factors == False
assert tel.import_from_stability_analysis_enabled == False
assert tel.determination_type == TimberEffectiveLengthsDeterminationType.DETERMINATION_EIGENVALUE_SOLVER.name
assert tel.nodal_supports[0][0].row.support_type == TimberEffectiveLengthsSupportType.SUPPORT_TYPE_FIXED_IN_Z_Y_AND_TORSION.name
assert tel.nodal_supports[0][0].row.support_in_z == True
assert tel.nodal_supports[0][0].row.eccentricity_type == TimberEffectiveLengthsEccentricityType.ECCENTRICITY_TYPE_NONE.name