[MODULE] +v1.1.0 from https://www.odoo.com/apps/7.0/account_financial_report_webkit/
[burette/account_financial_report_webkit.git] / tests / trial_balance.yml
1 -
2 In order to test the PDF Trial Balance webkit wizard I will print report with default setting
3 -
4 !python {model: account.account}: |
5 from datetime import datetime
6 ctx={}
7 data_dict = {'chart_account_id':ref('account.chart0')}
8 from tools import test_reports
9 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
10
11 -
12 In order to test the PDF Trial Balance webkit wizard I will print report as if we print it from an account
13 -
14 !python {model: account.account}: |
15 from datetime import datetime
16 ctx={}
17 data_dict = {'chart_account_id':ref('account.chart0')}
18 ctx.update({'model': 'account.account','active_ids':[ref('account.assets_view'), ref('account.liabilities_view')],'active_id': ref('account.assets_view')})
19 from tools import test_reports
20 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
21
22 -
23 In order to test the PDF Trial Balance webkit wizard I will print report with filters on period
24 -
25 !python {model: account.account}: |
26 from datetime import datetime
27 ctx={}
28 data_dict = {'chart_account_id':ref('account.chart0'), 'fiscalyear_id': ref('account.data_fiscalyear'),
29 'filter': 'filter_period', 'period_from': ref('account.period_1'), 'period_to': ref('account.period_12')}
30 from tools import test_reports
31 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
32
33 -
34 In order to test the PDF Trial Balance webkit wizard I will print report with filters on dates
35 -
36 !python {model: account.account}: |
37 from datetime import datetime
38 ctx={}
39 data_dict = {'chart_account_id':ref('account.chart0'), 'fiscalyear_id': ref('account.data_fiscalyear'),
40 'filter': 'filter_date', 'date_from': '%s-01-01' %(datetime.now().year), 'date_to': '%s-12-31' %(datetime.now().year)}
41 from tools import test_reports
42 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
43
44 -
45 In order to test the PDF Trial Balance webkit wizard I will print report with one comparison filtered by year
46 -
47 !python {model: account.account}: |
48 from datetime import datetime
49 ctx={}
50 data_dict = {'chart_account_id':ref('account.chart0'), 'fiscalyear_id': ref('account.data_fiscalyear'),
51 'comp0_filter': 'filter_year', 'comp0_fiscalyear_id': ref('account.data_fiscalyear')}
52 from tools import test_reports
53 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
54
55 -
56 In order to test the PDF Trial Balance webkit wizard I will print report with all comparisons filtered by year, period and date
57 -
58 !python {model: account.account}: |
59 from datetime import datetime
60 ctx={}
61 data_dict = {'chart_account_id':ref('account.chart0'), 'fiscalyear_id': ref('account.data_fiscalyear'),
62 'comp0_filter': 'filter_year', 'comp0_fiscalyear_id': ref('account.data_fiscalyear'),
63 'comp1_filter': 'filter_period', 'comp1_period_from': ref('account.period_1'), 'comp1_period_to': ref('account.period_12'),
64 'comp2_filter': 'filter_date', 'comp2_date_from': '%s-01-01' %(datetime.now().year), 'comp2_date_to': '%s-12-31' %(datetime.now().year)
65 }
66 from tools import test_reports
67 test_reports.try_report_action(cr, uid, 'action_account_trial_balance_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')