From c3ddb8c4b2d5eaeaa4259bfb95f09d35c635a7b6 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 9 Jan 2026 19:18:37 +0000 Subject: [PATCH 1/3] Add automated testing infrastructure - Add GitHub Actions workflow for CI/CD - Create Makefile with test target - Add test badge to README Implements automated testing as requested in issue #1. Reference: fsantanna/ttl-hash@64ac5e1 --- .github/workflows/test.yml | 22 ++++++++++++++++++++++ Makefile | 3 +++ README.md | 2 ++ 3 files changed, 27 insertions(+) create mode 100644 .github/workflows/test.yml create mode 100644 Makefile diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..b699ac7 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,22 @@ +name: Tests + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Install Lua + run: | + sudo apt-get update + sudo apt-get install -y lua5.4 + + - name: Run tests + run: make test diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..fe2bbe4 --- /dev/null +++ b/Makefile @@ -0,0 +1,3 @@ +.PHONY: test +test: + cd tst && lua5.4 all.lua diff --git a/README.md b/README.md index cb6a709..9d506f8 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # f-streams +[![Tests](https://github.com/lua-atmos/f-streams/actions/workflows/test.yml/badge.svg)](https://github.com/lua-atmos/f-streams/actions/workflows/test.yml) + ***Pull-based Streams for Lua*** [ From 1390211969ee92f24974b439dd09eddc1e7a26c6 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 9 Jan 2026 19:36:42 +0000 Subject: [PATCH 2/3] Remove Makefile and run tests directly in workflow Simplify the setup by running tests directly in the GitHub Actions workflow without needing a Makefile. --- .github/workflows/test.yml | 2 +- Makefile | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) delete mode 100644 Makefile diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b699ac7..f927cb8 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -19,4 +19,4 @@ jobs: sudo apt-get install -y lua5.4 - name: Run tests - run: make test + run: cd tst && lua5.4 all.lua diff --git a/Makefile b/Makefile deleted file mode 100644 index fe2bbe4..0000000 --- a/Makefile +++ /dev/null @@ -1,3 +0,0 @@ -.PHONY: test -test: - cd tst && lua5.4 all.lua From 87bbba5dc110817669eab33fd8099b4d7a2803fe Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 9 Jan 2026 19:38:59 +0000 Subject: [PATCH 3/3] Use reference-style links for test badge --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9d506f8..675d2a2 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # f-streams -[![Tests](https://github.com/lua-atmos/f-streams/actions/workflows/test.yml/badge.svg)](https://github.com/lua-atmos/f-streams/actions/workflows/test.yml) +[![Tests][badge]][test] ***Pull-based Streams for Lua*** @@ -9,6 +9,9 @@ [`v0.1`](https://github.com/lua-atmos/f-streams/tree/v0.1) ] +[badge]: https://github.com/lua-atmos/f-streams/actions/workflows/test.yml/badge.svg +[test]: https://github.com/lua-atmos/f-streams/actions/workflows/test.yml + This is the unstable `main` branch. Please, switch to stable [`v0.2`](https://github.com/lua-atmos/f-streams/tree/v0.2).