mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-12-23 10:12:21 +03:00
Add tests and regen expectations
This commit is contained in:
parent
8062693f3d
commit
5699352ce6
@ -2,11 +2,11 @@
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- - initial_ast: 466c3da8bb0bc3711a3071784e06a475abbd95c4afa46ce2149bdaf8fbabe6e4
|
||||
unrolled_ast: 466c3da8bb0bc3711a3071784e06a475abbd95c4afa46ce2149bdaf8fbabe6e4
|
||||
ssa_ast: 9455d0f91c594cacc93cba0358e1d40017f65765b59b18a341ea2966b4ecb1df
|
||||
flattened_ast: b0caf68c1a6fe8ee511a80829ab30c35630daa28f86b4be4bf25adf1a0a367a8
|
||||
inlined_ast: b0caf68c1a6fe8ee511a80829ab30c35630daa28f86b4be4bf25adf1a0a367a8
|
||||
dce_ast: b0caf68c1a6fe8ee511a80829ab30c35630daa28f86b4be4bf25adf1a0a367a8
|
||||
- - initial_ast: 20332c6a83a3628dd4f17d8653acdf28dd8e54bcaf9cab071fda7cbbf3ff3d29
|
||||
unrolled_ast: 20332c6a83a3628dd4f17d8653acdf28dd8e54bcaf9cab071fda7cbbf3ff3d29
|
||||
ssa_ast: 2bfa5ff05133abdf9553186a96a35c8466b5a49366ea07cea92e01f30c04f769
|
||||
flattened_ast: f7fd524a8a3e98f0e01f4c71b09bea3032867a086447ea72f4cdded1a581983d
|
||||
inlined_ast: f7fd524a8a3e98f0e01f4c71b09bea3032867a086447ea72f4cdded1a581983d
|
||||
dce_ast: 644ec7d38093f28ca0b0908282d7ff8032f7b22a0cf98c47d5ffa0ad16f047b8
|
||||
bytecode: 51e95e10668242bec30e9917715d9856da632e933c33207ee41c5ed38d6366aa
|
||||
warnings: ""
|
||||
|
@ -2,11 +2,11 @@
|
||||
namespace: Compile
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- - initial_ast: 6cc132d16506cefce980b7ecb6637bc89a6db79e90073c307dbb75a2a25e3251
|
||||
unrolled_ast: 6cc132d16506cefce980b7ecb6637bc89a6db79e90073c307dbb75a2a25e3251
|
||||
ssa_ast: 8b8a2daa8b7e32c23f2d3290ab3557b7b6d98afeb2ae55c35795de7e8180ef79
|
||||
flattened_ast: 00b4b6055c4035a3c016a88afa60f8504dec8542ad6413bd8340f75ce60564b2
|
||||
inlined_ast: 00b4b6055c4035a3c016a88afa60f8504dec8542ad6413bd8340f75ce60564b2
|
||||
dce_ast: 00b4b6055c4035a3c016a88afa60f8504dec8542ad6413bd8340f75ce60564b2
|
||||
- - initial_ast: 62e89c72fcd4f62002450d1c82060f2f662ad6e1c12a19f0e6b994c50ba0491b
|
||||
unrolled_ast: 62e89c72fcd4f62002450d1c82060f2f662ad6e1c12a19f0e6b994c50ba0491b
|
||||
ssa_ast: b3c38a64899eef777c4bdd38d5db3f68148334795f4e9b89449eb9148db03eb3
|
||||
flattened_ast: da24a573e4ff569e242f88f73869c2251e19bb5ae62ef602773c0a48863bb9b3
|
||||
inlined_ast: da24a573e4ff569e242f88f73869c2251e19bb5ae62ef602773c0a48863bb9b3
|
||||
dce_ast: d313e678afef867d5cbca6829c81515387bcc768eeb4044b25c7996f4d177c63
|
||||
bytecode: ea2e94f0f589fac4565040575643b1b7cd7813fe513d5b09b17c191bbf0f727e
|
||||
warnings: ""
|
||||
|
@ -2,13 +2,13 @@
|
||||
namespace: Execute
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- - initial_ast: 0f695b51ab88009feefe657770a42c5e87c5406b480c48636bf96170be3cd606
|
||||
unrolled_ast: 0f695b51ab88009feefe657770a42c5e87c5406b480c48636bf96170be3cd606
|
||||
ssa_ast: 5d78ad9fd293c3227d2a7ddadff8c7c0689794fe983ab4c8370683b2ba05643e
|
||||
flattened_ast: b50634e2bc12b8e27f6f6fc00cc8ab56407fdb5aec190992106cbf45143f7c96
|
||||
inlined_ast: b50634e2bc12b8e27f6f6fc00cc8ab56407fdb5aec190992106cbf45143f7c96
|
||||
dce_ast: b50634e2bc12b8e27f6f6fc00cc8ab56407fdb5aec190992106cbf45143f7c96
|
||||
bytecode: e556ad690ff212037476e85570be2afb974da528efb4688626d824a886f9013e
|
||||
- - initial_ast: ccfa20fa35d720984742081098965806736ba374ad046b3aadf6d899663375da
|
||||
unrolled_ast: ccfa20fa35d720984742081098965806736ba374ad046b3aadf6d899663375da
|
||||
ssa_ast: ab06973a60d8da80b174deae3dc4ee88216894503e613d3ba3ecd74c7f38e408
|
||||
flattened_ast: 9a9c3bc868b2e83c0cb0822e5bbf1d6f782f7992e0b748c6390a57768c44a4a7
|
||||
inlined_ast: 9a9c3bc868b2e83c0cb0822e5bbf1d6f782f7992e0b748c6390a57768c44a4a7
|
||||
dce_ast: 9a9c3bc868b2e83c0cb0822e5bbf1d6f782f7992e0b748c6390a57768c44a4a7
|
||||
bytecode: 5c20fda21a40464a1462524cf913438776a39383a671949312f48ce8ceb2dd16
|
||||
warnings: ""
|
||||
results:
|
||||
main:
|
||||
|
@ -0,0 +1,18 @@
|
||||
---
|
||||
namespace: ParseExpression
|
||||
expectation: Pass
|
||||
outputs:
|
||||
- Unary:
|
||||
receiver:
|
||||
Identifier: "{\"name\":\"a\",\"span\":\"{\\\"lo\\\":0,\\\"hi\\\":1}\"}"
|
||||
op: ToXCoordinate
|
||||
span:
|
||||
lo: 0
|
||||
hi: 19
|
||||
- Unary:
|
||||
receiver:
|
||||
Identifier: "{\"name\":\"b\",\"span\":\"{\\\"lo\\\":0,\\\"hi\\\":1}\"}"
|
||||
op: ToYCoordinate
|
||||
span:
|
||||
lo: 0
|
||||
hi: 19
|
@ -5,6 +5,8 @@ expectation: Pass
|
||||
|
||||
program test.aleo {
|
||||
transition main(a: group) -> field {
|
||||
let x: field = a.to_x_coordinate();
|
||||
let y: field = 0group.to_y_coordinate();
|
||||
return group::to_x_coordinate(a);
|
||||
}
|
||||
}
|
||||
|
@ -5,6 +5,8 @@ expectation: Pass
|
||||
|
||||
program test.aleo {
|
||||
transition main(a: group) -> field {
|
||||
let x: field = a.to_x_coordinate();
|
||||
let y: field = 0group.to_y_coordinate();
|
||||
return group::to_y_coordinate(a);
|
||||
}
|
||||
}
|
||||
|
@ -11,8 +11,12 @@ program test.aleo {
|
||||
transition main(a: group) -> (field, field) {
|
||||
let b: field = group::to_x_coordinate(a);
|
||||
let c: field = a as field;
|
||||
let e: field = a.to_x_coordinate();
|
||||
assert_eq(b, c);
|
||||
assert_eq(b, e);
|
||||
let d: field = group::to_y_coordinate(a);
|
||||
let f: field = a.to_y_coordinate();
|
||||
assert_eq(d, f);
|
||||
return (b, d);
|
||||
}
|
||||
}
|
||||
|
7
tests/tests/parser/expression/access/method_function.leo
Normal file
7
tests/tests/parser/expression/access/method_function.leo
Normal file
@ -0,0 +1,7 @@
|
||||
/*
|
||||
namespace: ParseExpression
|
||||
expectation: Pass
|
||||
*/
|
||||
|
||||
a.to_x_coordinate()
|
||||
b.to_y_coordinate()
|
Loading…
Reference in New Issue
Block a user