From 0024ea4b8d5147c34715f8295e21e042e594e1b3 Mon Sep 17 00:00:00 2001 From: alex-eg Date: Wed, 14 Oct 2026 23:22:38 +0300 Subject: [PATCH] take every program in tests/sex-programs as a test A program left out of the hand-kept list was never run, and nothing said so; the one module the tests import moves to lib/ instead. --- Makefile | 30 +++----------------- tests/sex-programs/{ => lib}/list-macros.sex | 0 tests/sex-programs/lists.sex | 2 +- 3 files changed, 5 insertions(+), 27 deletions(-) rename tests/sex-programs/{ => lib}/list-macros.sex (100%) diff --git a/Makefile b/Makefile index c116914..3ec402e 100644 --- a/Makefile +++ b/Makefile @@ -78,35 +78,13 @@ sex-tests: $(wildcard tests/*.scm) $(OBJ) sextest: tools/sextest/sextest.scm reader.o utils.o $(CHICKEN_C) $(CSC_FLAGS) $< -o $@ -link reader,utils -SEX_TEST_PROGRAMS = c11 \ - closure-signatures \ - closures \ - comments \ - compound-literals \ - encapsulation \ - feature-flags \ - features \ - fixpoint \ - hello-world \ - inference \ - lambdas \ - lists \ - operators \ - ops \ - precedence \ - records \ - serialize \ - specs \ - sums \ - threading \ - type-shapes \ - unicode \ - unnamed-params \ - wildcards +# A program directly in tests/sex-programs is a test; lib/ holds what +# they import +SEX_TEST_PROGRAMS = $(wildcard tests/sex-programs/*.sex) check run-tests: sexc sex-tests sextest ./sex-tests - ./sextest --sexc=./sexc $(SEX_TEST_PROGRAMS:%=./tests/sex-programs/%.sex) + ./sextest --sexc=./sexc $(SEX_TEST_PROGRAMS) cd tests/modules && SEXC=$(CURDIR)/sexc $(CSI) -s check.scm cd tests/exit-code && SEXC=$(CURDIR)/sexc $(CSI) -s check.scm diff --git a/tests/sex-programs/list-macros.sex b/tests/sex-programs/lib/list-macros.sex similarity index 100% rename from tests/sex-programs/list-macros.sex rename to tests/sex-programs/lib/list-macros.sex diff --git a/tests/sex-programs/lists.sex b/tests/sex-programs/lists.sex index e428a88..399555b 100644 --- a/tests/sex-programs/lists.sex +++ b/tests/sex-programs/lists.sex @@ -9,7 +9,7 @@ (include stddef.h) (include stdio.h) -(import list-macros) +(import lib/list-macros) (struct foo ((a-field float)