From 7af21dc1645fcdbb4db8216712d46a5c3ec2e8f8 Mon Sep 17 00:00:00 2001 From: Kreyren Date: Fri, 7 Feb 2020 18:14:15 +0000 Subject: [PATCH] fdhsfdh --- .github/workflows/cona-isa.yml | 1 + src/bin/main.v | 6 +++++- tests/vlang/hello_test.v | 5 +++++ 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 tests/vlang/hello_test.v diff --git a/.github/workflows/cona-isa.yml b/.github/workflows/cona-isa.yml index 7d975d6..ea70d97 100644 --- a/.github/workflows/cona-isa.yml +++ b/.github/workflows/cona-isa.yml @@ -121,6 +121,7 @@ jobs: [ ! -x "/opt/vlang/v" ] && unzip "$HOME/.cache/vlang-0.1.24.zip" -d /opt/vlang # Symlink [ ! -h "/usr/bin/v" ] && ln -sf /usr/bin/v /opt/vlang/v + ls -la /usr/bin/v - name: make build-vlang run: make build-vlang check-vlang: diff --git a/src/bin/main.v b/src/bin/main.v index e8acdc9..78287b2 100644 --- a/src/bin/main.v +++ b/src/bin/main.v @@ -1,3 +1,7 @@ +fn hello() { + printf("%s\n", "Hello World") +} + fn main() { - println("hello world") + hello() } \ No newline at end of file diff --git a/tests/vlang/hello_test.v b/tests/vlang/hello_test.v new file mode 100644 index 0000000..c4638f5 --- /dev/null +++ b/tests/vlang/hello_test.v @@ -0,0 +1,5 @@ +fn hellocheck() { + if hello != "Hello World" { + exit 1 + } +} \ No newline at end of file