mirror of
https://github.com/OCA/account-financial-tools.git
synced 2025-02-02 12:47:26 +02:00
[imp] account_move_batch_validate: with a little trick, tests are back!
This commit is contained in:
@@ -71,8 +71,8 @@
|
||||
'wizard/move_marker_view.xml',
|
||||
],
|
||||
'test': [
|
||||
# 'test/batch_validate.yml',
|
||||
# 'test/batch_validate_then_unmark.yml',
|
||||
'test/batch_validate.yml',
|
||||
'test/batch_validate_then_unmark.yml',
|
||||
],
|
||||
'installable': True,
|
||||
'images': [],
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
I run the wizard
|
||||
-
|
||||
!python {model: account.move.marker}: |
|
||||
context['automated_test_execute_now'] = True
|
||||
self.button_mark(
|
||||
cr, uid, [ref('wiz_marker1')], context=context
|
||||
)
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
I run the wizard
|
||||
-
|
||||
!python {model: account.move.marker}: |
|
||||
context['automated_test_execute_now'] = True
|
||||
self.button_mark(
|
||||
cr, uid, [ref('wiz_marker2')], context=context
|
||||
)
|
||||
|
||||
@@ -57,7 +57,11 @@ class AccountMoveMarker(orm.TransientModel):
|
||||
wizard_data = self.read(cr, uid, wizard_id, context=context,
|
||||
load='_classic_write')
|
||||
wizard_data.pop('id')
|
||||
process_wizard.delay(session, self._name, wizard_data)
|
||||
|
||||
if context.get('automated_test_execute_now'):
|
||||
process_wizard(session, self._name, wizard_data)
|
||||
else:
|
||||
process_wizard.delay(session, self._name, wizard_data)
|
||||
|
||||
return {'type': 'ir.actions.act_window_close'}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user