refactoring
This commit is contained in:
0
tests/flattener_dicos/10check_option/__init__.py
Normal file
0
tests/flattener_dicos/10check_option/__init__.py
Normal file
@ -6,17 +6,17 @@
|
||||
<variable doc="No change" multi="False" name="mode_conteneur_actif" type="string">
|
||||
<property>mandatory</property>
|
||||
<property>normal</property>
|
||||
<value>b</value>
|
||||
<value type="string">b</value>
|
||||
</variable>
|
||||
<variable doc="No change" multi="False" name="int2" type="number">
|
||||
<property>mandatory</property>
|
||||
<property>normal</property>
|
||||
<value>100</value>
|
||||
<value type="number">100</value>
|
||||
</variable>
|
||||
<variable doc="No change" multi="False" name="int" type="number">
|
||||
<check name="valid_entier" warnings_only="False">
|
||||
<param name="mini" type="string">0</param>
|
||||
<param name="maxi" type="variable">rougail.general.int2</param>
|
||||
<param name="maxi" notraisepropertyerror="False" type="variable">rougail.general.int2</param>
|
||||
</check>
|
||||
<property>normal</property>
|
||||
</variable>
|
||||
|
10
tests/flattener_dicos/10check_option/tiramisu/base.py
Normal file
10
tests/flattener_dicos/10check_option/tiramisu/base.py
Normal file
@ -0,0 +1,10 @@
|
||||
from tiramisu import *
|
||||
from rougail.tiramisu import ConvertDynOptionDescription
|
||||
import imp
|
||||
func = imp.load_source('func', 'tests/flattener_dicos/../eosfunc/test.py')
|
||||
option_3 = StrOption(properties=frozenset(['mandatory', 'normal']), doc='No change', multi=False, name='mode_conteneur_actif', default='b')
|
||||
option_4 = IntOption(properties=frozenset(['mandatory', 'normal']), doc='No change', multi=False, name='int2', default=100)
|
||||
option_5 = IntOption(properties=frozenset(['normal']), validators=[Calculation(func.valid_entier, Params((ParamSelfOption()), kwargs={'mini': ParamValue("0"), 'maxi': ParamOption(option_4, notraisepropertyerror=False, todict=False)}), warnings_only=False)], doc='No change', multi=False, name='int')
|
||||
option_2 = OptionDescription(doc='general', name='general', properties=frozenset(['normal']), children=[option_3, option_4, option_5])
|
||||
option_1 = OptionDescription(doc='rougail', name='rougail', children=[option_2])
|
||||
option_0 = OptionDescription(name='baseoption', doc='baseoption', children=[option_1])
|
Reference in New Issue
Block a user