From de809dda5ebaf0d1e9872afc940ee9ba511f3699 Mon Sep 17 00:00:00 2001 From: Andrea Mazzoleni Date: Wed, 26 Aug 2026 11:08:00 +0200 Subject: [PATCH] Add SHORTCHECK variable to Makefile to control test dataset size --- .github/workflows/build.yml | 2 +- Makefile.am | 24 +++++++++++------------- 2 files changed, 12 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6ded7dc5..e959f071 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -54,7 +54,7 @@ jobs: -cpu cortex-a15 \ -L /usr/arm-linux-gnueabihf \ ./snapraid -V - - run: make check + - run: make check SHORTCHECK=1 build-win: runs-on: windows-latest defaults: diff --git a/Makefile.am b/Makefile.am index 7aa7750a..9dee688f 100644 --- a/Makefile.am +++ b/Makefile.am @@ -301,23 +301,21 @@ CHECKFLAGS = $(CHECKFLAGS_ALPHA) -q -q -q # Snapshots with no parity limit CHECKFLAGS_SNAP = --test-skip-device --test-skip-self --test-io-advise-none --test-force-order-alpha -q -q -q -# Number of files to create -if !HAVE_MEMORY_CHECKER -if HAVE_POSIX -CHECKCOUNT = 1000 -else -CHECKCOUNT = 500 +# Short check options +if HAVE_MEMORY_CHECKER +SHORTCHECK = 1 endif +SHORTCHECK ?= 0 + +# Number of files to create +if HAVE_POSIX +CHECKCOUNT_DEFAULT = 1000 else -CHECKCOUNT = 500 +CHECKCOUNT_DEFAULT = 500 endif -# Size of files to create -if !HAVE_MEMORY_CHECKER -CHECKSIZE = 4000 -else -CHECKSIZE = 100 -endif +CHECKCOUNT = $(if $(filter 1,$(SHORTCHECK)),500,$(CHECKCOUNT_DEFAULT)) +CHECKSIZE = $(if $(filter 1,$(SHORTCHECK)),100,4000) CONF = $(srcdir)/test/test-par6.conf THERMAL = $(srcdir)/test/test-par6-thermal.conf