~unifield-team/unifield-wm/us-826

« back to all changes in this revision

Viewing changes to analytic_distribution/test/bug_2217.yml

  • Committer: Quentin THEURET
  • Date: 2011-12-12 08:02:59 UTC
  • mto: This revision was merged to the branch mainline in revision 724.
  • Revision ID: qt@tempo-consulting.fr-20111212080259-oul1f0g37hcpubyc
UF-641 [ADD] Added the empty purchase_followup module

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
-
2
 
  I create an analytic account
3
 
-
4
 
  !record {model: account.analytic.account, id: anacc1}:
5
 
    name: "AN1"
6
 
    currency_id: 1
7
 
    code: AN1
8
 
    type: normal
9
 
    category: OC
10
 
    parent_id: analytic_distribution.analytic_account_project
11
 
    date: !eval "'%s-01-01' %(datetime.now().year + 2)"
12
 
 
13
 
-
14
 
  I create an Expense Account Type.
15
 
-
16
 
  !record {model: account.account.type, id: acc_type_exp}:
17
 
    close_method: unreconciled
18
 
    code: expense
19
 
    name: Expense
20
 
    sign: 1
21
 
-
22
 
  Expense Account.
23
 
-
24
 
  !record {model: account.account, id: acc1}:
25
 
    code: '666'
26
 
    company_id: base.main_company
27
 
    name: Expense Account
28
 
    type: other
29
 
    user_type: acc_type_exp
30
 
-
31
 
  Analytic Journal Creation
32
 
-
33
 
  !record {model: account.analytic.journal, id: alj1}:
34
 
    code: toto
35
 
    company_id: base.main_company
36
 
    name: toto
37
 
    type: sale
38
 
-
39
 
  I create analytic line with an entry sequence
40
 
-
41
 
  !record {model: account.analytic.line, id: test_analytic}:
42
 
    journal_id: alj1
43
 
    amount: 100
44
 
    name: test1
45
 
    date: !eval "time.strftime('%Y-%m-%d')"
46
 
    account_id: anacc1
47
 
    general_account_id: acc1
48
 
    currency_id: base.EUR
49
 
    amount_currency: 100
50
 
    document_date: !eval "time.strftime('%Y-%m-%d')"
51
 
    entry_sequence: ABCD
52
 
-
53
 
  I check the entry is set
54
 
-
55
 
  !python {model: account.analytic.line,}: |
56
 
    al = self.read(cr, uid, ref('test_analytic'), ['entry_sequence'])
57
 
    assert al['entry_sequence'] == 'ABCD', 'The field entry_sequence is not set on creation'