From 857d68708babcac0122908b75dfe14684c202c18 Mon Sep 17 00:00:00 2001 From: Felipe Contreras Date: Sun, 5 Mar 2023 22:32:27 -0600 Subject: [PATCH 1/3] test: trivial cleanups TEST_DIRECTORY doesn't even exist in sharness. Signed-off-by: Felipe Contreras --- test/Makefile | 4 ++-- test/bidi.t | 3 +-- test/hg-git.t | 3 +-- test/main.t | 3 +-- 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/test/Makefile b/test/Makefile index 13915fe..00d63a1 100644 --- a/test/Makefile +++ b/test/Makefile @@ -1,9 +1,9 @@ RM ?= rm -f T = main.t bidi.t -TEST_DIRECTORY := $(CURDIR) +SHARNESS_TEST_DIRECTORY := $(CURDIR) -export TEST_DIRECTORY +export SHARNESS_TEST_DIRECTORY all: test diff --git a/test/bidi.t b/test/bidi.t index cbcb0bd..b6d2bbb 100755 --- a/test/bidi.t +++ b/test/bidi.t @@ -8,8 +8,7 @@ test_description='Test bidirectionality of remote-hg' -test -n "$TEST_DIRECTORY" || TEST_DIRECTORY=$(dirname $0)/ -. "$TEST_DIRECTORY"/test-lib.sh +. ./test-lib.sh if ! test_have_prereq PYTHON then diff --git a/test/hg-git.t b/test/hg-git.t index ba3995e..58a78a8 100755 --- a/test/hg-git.t +++ b/test/hg-git.t @@ -8,8 +8,7 @@ test_description='Test remote-hg output compared to hg-git' -test -n "$TEST_DIRECTORY" || TEST_DIRECTORY=$(dirname $0)/ -. "$TEST_DIRECTORY"/test-lib.sh +. ./test-lib.sh if ! test_have_prereq PYTHON then diff --git a/test/main.t b/test/main.t index 249ae39..8fd35fe 100755 --- a/test/main.t +++ b/test/main.t @@ -8,8 +8,7 @@ test_description='Test remote-hg' -test -n "$TEST_DIRECTORY" || TEST_DIRECTORY=$(dirname $0)/ -. "$TEST_DIRECTORY"/test-lib.sh +. ./test-lib.sh if ! test_have_prereq PYTHON then From de9bf3538837d0a8ff65e81ee0c9053f8332312d Mon Sep 17 00:00:00 2001 From: Felipe Contreras Date: Sun, 5 Mar 2023 22:40:09 -0600 Subject: [PATCH 2/3] test: include sharness properly So that it can be overridden. Signed-off-by: Felipe Contreras --- test/test-lib.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/test-lib.sh b/test/test-lib.sh index b14e32c..727083e 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -1,6 +1,7 @@ #!/bin/sh -. ./sharness.sh +: "${SHARNESS_TEST_SRCDIR:=$(cd "$(dirname "${BASH_SOURCE-$0}")" && pwd)}" +. "$SHARNESS_TEST_SRCDIR"/sharness.sh test_set_prereq PYTHON From b4c3277f72f995cc0babcdc5bc6f6d0e2254acc3 Mon Sep 17 00:00:00 2001 From: Felipe Contreras Date: Mon, 6 Mar 2023 09:42:51 -0600 Subject: [PATCH 3/3] github: trigger actions on all branches Signed-off-by: Felipe Contreras --- .github/workflows/main.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 724ed37..0014115 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,6 +1,5 @@ on: push: - branches: [ master ] jobs: test: