diff --git a/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_acceptDecisionForTesting.xml b/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_acceptDecisionForTesting.xml new file mode 100644 index 0000000000000000000000000000000000000000..f01b8a2c6b95233f998925dad92113cc29a36e11 --- /dev/null +++ b/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_acceptDecisionForTesting.xml @@ -0,0 +1,133 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>_bind_names</string> </key> + <value> + <object> + <klass> + <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>_asgns</string> </key> + <value> + <dictionary> + <item> + <key> <string>name_container</string> </key> + <value> <string>container</string> </value> + </item> + <item> + <key> <string>name_context</string> </key> + <value> <string>context</string> </value> + </item> + <item> + <key> <string>name_m_self</string> </key> + <value> <string>script</string> </value> + </item> + <item> + <key> <string>name_subpath</string> </key> + <value> <string>traverse_subpath</string> </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>_body</string> </key> + <value> <string>divergence_list = []\n +for divergence_message in context.getDivergenceList():\n + if divergence_message.getProperty(\'tested_property\') == solver_target:\n + divergence_list.append(divergence_message)\n +simulation_tool = context.getPortalObject().portal_simulation\n +simulation_tool.solveDelivery(context, None, \'Copy\', divergence_list=divergence_list)\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>solver_target</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>solver_target</string> + <string>divergence_list</string> + <string>_getiter_</string> + <string>_getattr_</string> + <string>context</string> + <string>divergence_message</string> + <string>simulation_tool</string> + <string>None</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>SalePackingList_acceptDecisionForTesting</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_adoptPrevisionForTesting.xml b/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_adoptPrevisionForTesting.xml new file mode 100644 index 0000000000000000000000000000000000000000..402c86c1aeca1bcc3b3d347ff3528258755fd66f --- /dev/null +++ b/bt5/erp5_simulation_performance_test/SkinTemplateItem/portal_skins/erp5_simulation_performance_test/SalePackingList_adoptPrevisionForTesting.xml @@ -0,0 +1,135 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>_bind_names</string> </key> + <value> + <object> + <klass> + <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>_asgns</string> </key> + <value> + <dictionary> + <item> + <key> <string>name_container</string> </key> + <value> <string>container</string> </value> + </item> + <item> + <key> <string>name_context</string> </key> + <value> <string>context</string> </value> + </item> + <item> + <key> <string>name_m_self</string> </key> + <value> <string>script</string> </value> + </item> + <item> + <key> <string>name_subpath</string> </key> + <value> <string>traverse_subpath</string> </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>_body</string> </key> + <value> <string>delivery_tool = context.getPortalObject().portal_deliveries\n +delivery_builder = delivery_tool.test_sale_packing_list_builder\n +divergence_list = []\n +for divergence_message in context.getDivergenceList():\n + if divergence_message.getProperty(\'tested_property\') == solver_target:\n + divergence_list.append(divergence_message)\n +delivery_builder.solveDivergence(context.getRelativeUrl(),\n + divergence_to_adopt_list=divergence_list)\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>solver_target</string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>solver_target</string> + <string>_getattr_</string> + <string>context</string> + <string>delivery_tool</string> + <string>delivery_builder</string> + <string>divergence_list</string> + <string>_getiter_</string> + <string>divergence_message</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>SalePackingList_adoptPrevisionForTesting</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_simulation_performance_test/bt/change_log b/bt5/erp5_simulation_performance_test/bt/change_log index 49049a702c7255fdf3b36c4306f1c4ecdd3e93fe..ecfc5874b3fd1f6665cf2fa18365f477db724d71 100644 --- a/bt5/erp5_simulation_performance_test/bt/change_log +++ b/bt5/erp5_simulation_performance_test/bt/change_log @@ -1,3 +1,6 @@ +2010-08-08 yo +* Add helper scripts to deal with divergence in a legacy way. + 2010-08-07 yo * Split the category movement group into an updatable one and a non-updatable one, to have some categories to be changeable without making another delivery. diff --git a/bt5/erp5_simulation_performance_test/bt/revision b/bt5/erp5_simulation_performance_test/bt/revision index bf0d87ab1b2b0ec1a11a3973d2845b42413d9767..7813681f5b41c028345ca62a2be376bae70b7f61 100644 --- a/bt5/erp5_simulation_performance_test/bt/revision +++ b/bt5/erp5_simulation_performance_test/bt/revision @@ -1 +1 @@ -4 \ No newline at end of file +5 \ No newline at end of file