From b6b5a9b7cf95030c767ec618e0cd2df73783a21b Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Tue, 9 Jun 2026 07:53:12 -0500 Subject: build(theme-studio): add a local Makefile; root delegates test + coverage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit theme-studio is a self-contained Python + JS subproject with its own toolchain (python3, node, uvx, headless Chrome), unrelated to the root Makefile's Elisp/ERT world. Gave it a local Makefile that owns that toolchain — test, check (fast, no browser), coverage, gen, open — so the build logic lives with the code and the short target names don't collide with the root's Elisp-flavored test/coverage. The root keeps the discoverable entry points: theme-studio-test and a new theme-studio-coverage now delegate via make -C. run-tests.sh grows a --no-browser flag so `make check` can skip the headless-Chrome gates for a fast inner loop. gen/open take an optional SEED to view a specific palette. coverage reports both halves: node --experimental-test-coverage for the three JS modules (all 100% line, ~96% branch) and uvx coverage for generate.py (89% lines; the rest is the __main__ writer and the optional seed-env branch). --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index a1f403e8..85da255d 100644 --- a/Makefile +++ b/Makefile @@ -46,7 +46,7 @@ EMACS_TEST = $(EMACS_BATCH) -L $(TEST_DIR) -L $(MODULE_DIR) # No colors - using plain text symbols instead .PHONY: help targets test test-all test-unit test-integration test-file test-name \ - test-bash theme-studio-test benchmark coverage coverage-summary coverage-clean \ + test-bash theme-studio-test theme-studio-coverage benchmark coverage coverage-summary coverage-clean \ validate-parens validate-modules compile compile-file lint profile \ clean clean-compiled clean-tests reset @@ -67,6 +67,7 @@ help: @echo " make test-name TEST= - Run tests matching pattern" @echo " make test-bash - Run the bats shell-script tests ($(words $(BASH_TESTS)) files)" @echo " make theme-studio-test - Run the theme-studio tool tests (Python + Node + browser)" + @echo " make theme-studio-coverage - Coverage for the theme-studio JS + generate.py" @echo " make benchmark - Run performance benchmarks (:perf-tagged)" @echo "" @echo " Coverage:" @@ -123,7 +124,10 @@ test-bash: @bats $(BASH_TESTS) theme-studio-test: - @scripts/theme-studio/run-tests.sh + @$(MAKE) -C scripts/theme-studio test + +theme-studio-coverage: + @$(MAKE) -C scripts/theme-studio coverage BANNER = ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ -- cgit v1.2.3