Skip to content

Commit 47325cb

Browse files
committed
test: added skipped test
1 parent d239b51 commit 47325cb

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

internal/interpreter/interpreter_test.go

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4266,6 +4266,39 @@ func TestThroughNestedRightSide(t *testing.T) {
42664266
test(t, tc)
42674267
}
42684268

4269+
func TestWithinInorder(t *testing.T) {
4270+
t.Skip("Fix postings order")
4271+
4272+
script := `
4273+
send [COIN 10] (
4274+
source = {
4275+
max [COIN 2] from @a allowing unbounded overdraft
4276+
@b through @proxy // balance=1
4277+
@world //left=7
4278+
}
4279+
destination = @dest
4280+
)
4281+
`
4282+
4283+
tc := NewTestCase()
4284+
tc.compile(t, script)
4285+
tc.setBalance("b", "COIN", 1)
4286+
tc.expected = CaseResult{
4287+
Postings: []Posting{
4288+
4289+
{Source: "a", Destination: "dest", Amount: big.NewInt(2), Asset: "COIN"},
4290+
4291+
{Source: "b", Destination: "proxy", Amount: big.NewInt(1), Asset: "COIN"},
4292+
{Source: "proxy", Destination: "dest", Amount: big.NewInt(1), Asset: "COIN"},
4293+
4294+
{Source: "world", Destination: "dest", Amount: big.NewInt(7), Asset: "COIN"},
4295+
},
4296+
Error: nil,
4297+
}
4298+
4299+
test(t, tc)
4300+
}
4301+
42694302
func TestColorSend(t *testing.T) {
42704303
script := `
42714304
send [COIN 100] (

0 commit comments

Comments
 (0)