Skip to content

Commit

Permalink
Add basic CI, move broken bins to broken so make test succeeds
Browse files Browse the repository at this point in the history
  • Loading branch information
nyetwurk committed Oct 27, 2024
1 parent e503ccc commit 2d23438
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 2 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/c-cpp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: C/C++ CI

on:
push:
# branches: [ $default-branch ]
pull_request:
branches: [ $default-branch ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- name: install libgmp-dev
run: |
sudo apt-get update
sudo apt-get install -y libgmp-dev
- uses: actions/checkout@v4
- name: make
run: make
- name: make test
run: make test
4 changes: 4 additions & 0 deletions GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ endif

include makefile.common

.PHONY: test
test:
./test.sh

win: force
./build.cmd clean
./build.cmd
Expand Down
File renamed without changes.
File renamed without changes.
10 changes: 8 additions & 2 deletions test.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
#!/bin/sh

rm -f err.log
trap "rm -rf err.log" EXIT
for i in bins/*.bin; do
./me7sum -r $i.txt $i | grep -E '(ABORT|WARNING)'
grep ERROR $i.txt
./me7sum -r $i.txt $i | grep -E '(ABORT|WARNING)' >> err.log
grep ERROR $i.txt >> err.log
done

cat err.log
[ ! -s err.log ]

0 comments on commit 2d23438

Please sign in to comment.