all repos

clerk @ e2e9e2b

missing tooling for ledger/hledger

clerk/journal/parser/testdata/virtual_postings_with_statuses.txtar (view raw)

Oleksandr Smirnov Oleksandr Smirnov
olexsmir@gmail.com
tests: switch to txtar, 3 days ago
1
-- input --
2
2024/01/01 test
3
  ! (assets:cash)  $10
4
  (income:gift)  $-10
5
6
2024/01/01 test
7
    (! assets:cash)  $10
8
    (income:gift)  $-10
9
10
2024/01/01 test
11
    ! (! assets:cash)  $10
12
    (* income:gift)  $-10
13
-- expect --
14
Journal
15
  Transaction j:1:1-5:0
16
    Date: 2024/01/01
17
    Payee: "test" j:1:12-2:0
18
    Posting j:2:1-3:1
19
      Type: unbalanced virtual
20
      Status: "!"
21
      Account j:2:6-2:17
22
        SubAccount: "assets" j:2:6-2:12
23
        SubAccount: "cash" j:2:13-2:17
24
      Amount j:2:20-2:20
25
        Quantity: 10
26
        Commodity: "$"
27
        CommodityPos: Before
28
        HasSpace: false
29
        Precision: 0
30
        Decimal: "."
31
    Posting j:3:1-5:0
32
      Type: unbalanced virtual
33
      Account j:3:4-3:15
34
        SubAccount: "income" j:3:4-3:10
35
        SubAccount: "gift" j:3:11-3:15
36
      Amount j:3:18-3:18
37
        Quantity: -10
38
        Commodity: "$"
39
        CommodityPos: Before
40
        HasSpace: false
41
        Precision: 0
42
        Decimal: "."
43
  BlankLine j:5:0-5:1
44
  Transaction j:5:1-9:0
45
    Date: 2024/01/01
46
    Payee: "test" j:5:12-6:0
47
    Posting j:6:1-7:1
48
      Type: unbalanced virtual
49
      Status: "!"
50
      Account j:6:8-6:19
51
        SubAccount: "assets" j:6:8-6:14
52
        SubAccount: "cash" j:6:15-6:19
53
      Amount j:6:22-6:22
54
        Quantity: 10
55
        Commodity: "$"
56
        CommodityPos: Before
57
        HasSpace: false
58
        Precision: 0
59
        Decimal: "."
60
    Posting j:7:1-9:0
61
      Type: unbalanced virtual
62
      Account j:7:6-7:17
63
        SubAccount: "income" j:7:6-7:12
64
        SubAccount: "gift" j:7:13-7:17
65
      Amount j:7:20-7:20
66
        Quantity: -10
67
        Commodity: "$"
68
        CommodityPos: Before
69
        HasSpace: false
70
        Precision: 0
71
        Decimal: "."
72
  BlankLine j:9:0-9:1
73
  Transaction j:9:1-12:1
74
    Date: 2024/01/01
75
    Payee: "test" j:9:12-10:0
76
    Posting j:10:1-11:1
77
      Type: unbalanced virtual
78
      Status: "!"
79
      Account j:10:10-10:21
80
        SubAccount: "assets" j:10:10-10:16
81
        SubAccount: "cash" j:10:17-10:21
82
      Amount j:10:24-10:24
83
        Quantity: 10
84
        Commodity: "$"
85
        CommodityPos: Before
86
        HasSpace: false
87
        Precision: 0
88
        Decimal: "."
89
    Posting j:11:1-12:1
90
      Type: unbalanced virtual
91
      Status: "*"
92
      Account j:11:8-11:19
93
        SubAccount: "income" j:11:8-11:14
94
        SubAccount: "gift" j:11:15-11:19
95
      Amount j:11:22-11:22
96
        Quantity: -10
97
        Commodity: "$"
98
        CommodityPos: Before
99
        HasSpace: false
100
        Precision: 0
101
        Decimal: "."