all repos

clerk @ 2f5968c

missing tooling for ledger/hledger

clerk/journal/parser/testdata/transaction_with_costs.golden (view raw)

Oleksandr Smirnov Oleksandr Smirnov
olexsmir@gmail.com
parser: separate account names by :, 1 month ago
1
Journal
2
  Transaction j:1:1-5:0
3
    Date: 2026-05-11
4
    Payee: "testies" j:1:12-2:0
5
    Posting j:2:1-3:1
6
      Account j:2:2-2:14
7
        SubAccount: "expenses" j:2:2-2:10
8
        SubAccount: "atm" j:2:11-2:14
9
      Amount j:2:16-2:16
10
        Quantity: 20
11
        Commodity: "UAH"
12
        CommodityPos: After
13
        HasSpace: true
14
        Precision: 2
15
        Decimal: "."
16
      Cost(unit) j:2:26-3:0
17
        Amount j:2:28-2:28
18
          Quantity: 1
19
          Commodity: "USD"
20
          CommodityPos: After
21
          HasSpace: true
22
          Precision: 0
23
          Decimal: "."
24
    Posting j:3:1-5:0
25
      Account j:3:2-4:0
26
        SubAccount: "assets" j:3:2-3:8
27
        SubAccount: "bank" j:3:9-4:0
28
      Amount: <elided>
29
  BlankLine j:5:0-5:1
30
  Transaction j:5:1-9:0
31
    Date: 2026-05-11
32
    Payee: "testies2" j:5:12-6:0
33
    Posting j:6:1-7:1
34
      Account j:6:2-6:14
35
        SubAccount: "expenses" j:6:2-6:10
36
        SubAccount: "atm" j:6:11-6:14
37
      Amount j:6:16-6:16
38
        Quantity: 20
39
        Commodity: "UAH"
40
        CommodityPos: After
41
        HasSpace: true
42
        Precision: 2
43
        Decimal: "."
44
      Cost(total) j:6:26-7:0
45
        Amount j:6:29-6:29
46
          Quantity: 1
47
          Commodity: "USD"
48
          CommodityPos: After
49
          HasSpace: true
50
          Precision: 0
51
          Decimal: "."
52
    Posting j:7:1-9:0
53
      Account j:7:2-8:0
54
        SubAccount: "assets" j:7:2-7:8
55
        SubAccount: "bank" j:7:9-8:0
56
      Amount: <elided>
57
  BlankLine j:9:0-9:1
58
  Transaction j:9:1-13:0
59
    Date: 2026-05-12
60
    Payee: "testies3" j:9:12-10:0
61
    Posting j:10:1-11:1
62
      Account j:10:2-10:14
63
        SubAccount: "expenses" j:10:2-10:10
64
        SubAccount: "atm" j:10:11-10:14
65
      Amount j:10:16-10:16
66
        Quantity: 20
67
        Commodity: "UAH"
68
        CommodityPos: After
69
        HasSpace: true
70
        Precision: 2
71
        Decimal: "."
72
      Cost(unit) j:10:26-10:33
73
        Amount j:10:28-10:28
74
          Quantity: 1
75
          Commodity: "USD"
76
          CommodityPos: After
77
          HasSpace: true
78
          Precision: 0
79
          Decimal: "."
80
      BalanceAssertion j:10:34-10:45
81
        IsStrict: false
82
        IsInclusive: false
83
        Amount j:10:36-10:36
84
          Quantity: 20
85
          Commodity: "UAH"
86
          CommodityPos: After
87
          HasSpace: true
88
          Precision: 2
89
          Decimal: "."
90
    Posting j:11:1-13:0
91
      Account j:11:2-12:0
92
        SubAccount: "assets" j:11:2-11:8
93
        SubAccount: "bank" j:11:9-12:0
94
      Amount: <elided>
95
  BlankLine j:13:0-13:1
96
  Transaction j:13:1-16:1
97
    Date: 2015-01-03
98
    Payee: "money exchange office" j:13:12-14:0
99
    Posting j:14:1-15:1
100
      Account j:14:5-14:16
101
        SubAccount: "assets" j:14:5-14:11
102
        SubAccount: "cash" j:14:12-14:16
103
      Amount j:14:18-14:18
104
        Quantity: -20
105
        Commodity: "EUR"
106
        CommodityPos: After
107
        HasSpace: true
108
        Precision: 0
109
        Decimal: "."
110
      Cost(unit) j:14:26-15:0
111
        Amount j:14:28-14:28
112
          Quantity: 7.53
113
          Commodity: "HRK"
114
          CommodityPos: After
115
          HasSpace: true
116
          Precision: 2
117
          Decimal: "."
118
    Posting j:15:1-16:1
119
      Account j:15:5-15:16
120
        SubAccount: "assets" j:15:5-15:11
121
        SubAccount: "cash" j:15:12-15:16
122
      Amount j:15:18-15:18
123
        Quantity: 150.6
124
        Commodity: "HRK"
125
        CommodityPos: After
126
        HasSpace: true
127
        Precision: 2
128
        Decimal: "."