leo run helloworld in circleci

This commit is contained in:
collin 2022-08-08 11:15:11 -07:00
parent 46f21c68a2
commit 59bcaa9a60
6 changed files with 20 additions and 15 deletions

View File

@ -163,6 +163,19 @@ jobs:
export LEO=/home/circleci/project/project/bin/leo
./project/.circleci/leo-clean.sh
test-helloworld:
docker:
- image: cimg/rust:1.62
resource_class: xlarge
steps:
- attach_workspace:
at: /home/circleci/project/
- run:
name: test helloworld
command: |
export LEO=/home/circleci/project/project/bin/leo
./project/.circleci/test-helloworld.sh
workflows:
version: 2
main-workflow:

View File

@ -3,5 +3,5 @@ $LEO new foo
ls -la
cd foo && ls -la
# Try to run `leo build`.
# Try to run `leo run`.
$LEO run

View File

@ -0,0 +1,5 @@
# Build and run the helloworld Leo program.
cd ./project/examples/helloworld
# Run `leo run`.
$LEO run

View File

@ -1,8 +0,0 @@
circuit Foo {
x: u64,
y: u64,
}
function bar(x: u64, y: u64) -> Foo {
return Foo {x, y};
}

View File

@ -1,7 +1,4 @@
// The program input for helloworld/src/main.leo
[main]
public a: u32 = 1u32;
b: u32 = 2u32; // Input variable `b` is private by default.
[foo]
x: u64 = 5u64;
b: u32 = 2u32; // Input variable `b` is private by default.

View File

@ -1,5 +1,3 @@
import foo.leo;
// The 'helloworld' main function.
function main(public a: u32, b: u32) -> u32 {