diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml new file mode 100644 index 0000000..234b350 --- /dev/null +++ b/.github/workflows/workflow.yml @@ -0,0 +1,14 @@ +name: tests + +on: [ push ] + +jobs: + build: + name: tests + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - run: sudo apt install libcunit1-dev + - run: cd .. && git clone https://github.com/herumi/mcl && cd mcl && make -j8 + - run: make test diff --git a/Makefile b/Makefile index b5e5795..733e33a 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -MAIN = test +MAIN = tests OUT = zpie CC = gcc CAARCH64 = aarch64-linux-gnu-gcc diff --git a/README.md b/README.md index f514b75..6530c16 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,8 @@ # ZPiE: Zero-knowledge Proofs in Embedded systems +![Build Status](https://github.com/xevisalle/zpie/workflows/tests/badge.svg) +[![Repository](https://img.shields.io/badge/github-zpie-blueviolet?logo=github)](https://github.com/xevisalle/zpie) + A portable and efficient C library for developing Zero-Knowledge applications for embedded systems. **DISCLAIMER**: this library is currently **unstable**. Furthermore, **it has not gone through an exhaustive security analysis**, so it is not intended to be used in a production environment, only for academic purposes. diff --git a/src/tests.c b/src/tests.c index 7e399b7..8342a1c 100644 --- a/src/tests.c +++ b/src/tests.c @@ -163,6 +163,7 @@ int main() } CU_basic_run_tests(); + if(CU_get_number_of_failures()) abort(); CU_cleanup_registry(); return CU_get_error();