From b170ee36c5939bf967296429ec451e6fb116265b Mon Sep 17 00:00:00 2001 From: Dror Tirosh Date: Tue, 29 Oct 2024 15:45:54 +0200 Subject: [PATCH 1/2] updated to "docker compose" --- empty.yml | 1 - runbundler/run2bundlers.yml | 1 - runbundler/runbundler.sh | 2 +- runbundler/runbundler.yml | 1 - 4 files changed, 1 insertion(+), 4 deletions(-) diff --git a/empty.yml b/empty.yml index 025837f..0667b28 100644 --- a/empty.yml +++ b/empty.yml @@ -1,4 +1,3 @@ #first "docker-compose" file referenced by "runbundler" #Used to make sure all paths are relative to project root, #regardless from where the "real" docker-compose is loaded. -version: '3' diff --git a/runbundler/run2bundlers.yml b/runbundler/run2bundlers.yml index 2e35b9c..fcc0666 100644 --- a/runbundler/run2bundlers.yml +++ b/runbundler/run2bundlers.yml @@ -1,5 +1,4 @@ # docker-compose to bring up a single bundler, with all needed services -version: '3' services: diff --git a/runbundler/runbundler.sh b/runbundler/runbundler.sh index 1f08391..a7ba822 100755 --- a/runbundler/runbundler.sh +++ b/runbundler/runbundler.sh @@ -60,7 +60,7 @@ case "$file" in esac -DC="docker-compose $DCPARAMS -f $root/empty.yml -f $DCFILE" +DC="docker compose $DCPARAMS -f $root/empty.yml -f $DCFILE" cmd=$cmd case "$cmd" in diff --git a/runbundler/runbundler.yml b/runbundler/runbundler.yml index c664ce4..d39f34a 100644 --- a/runbundler/runbundler.yml +++ b/runbundler/runbundler.yml @@ -1,5 +1,4 @@ # docker-compose to bring up a single bundler, with all needed services -version: '3' services: From 238b5429ee97fecd078417189fec5b328cedd1ea Mon Sep 17 00:00:00 2001 From: Dror Tirosh Date: Tue, 29 Oct 2024 17:38:37 +0200 Subject: [PATCH 2/2] "./runall tests" runs all p2p tests runall now accept a folder (with yml/env files) and run them all. --- runall.sh | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/runall.sh b/runall.sh index 21a5c47..6d545dd 100755 --- a/runall.sh +++ b/runall.sh @@ -11,12 +11,28 @@ test -d bundler-spec-tests || git clone -b releases/v0.6 --recurse-submodules ht #by default, run all single-bundler configs BUNDLERS=`ls $root/bundlers/*/*yml|grep -v p2p` -#if parameter is given, use it as single-bundler yml, or as testenv file -if [ -n "$1" -a -r "$1" ]; then -BUNDLERS=`realpath $1` -shift +#if parameter is given, use it as single-bundler yml, or as testenv file, or a folder of testenv files +if [ -n "$1" ]; then + if [ -d "$1" ]; then + # a folder. collect all files in it + BUNDLERS="" + for t in $1/*; do + case $t in + *.yml|*.env) + BUNDLERS="$BUNDLERS `realpath $t`" + ;; + *) + echo "FATAL: $t is not '.env' or '.yml' file" + exit 1 + esac + done + + elif [ -r "$1" ]; then + # a single-file test + BUNDLERS=`realpath $1` + shift + fi fi - cd bundler-spec-tests #first time must runall.