From 67d3443999bfe3ef2f5e8d5d06c7ddb86149e26e Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Wed, 21 Oct 2020 12:21:02 +0200 Subject: [PATCH] tests: Fix unnecessary rebuilds of the test platform The code to use the pre-generated test platform was buggy so it wasn't used. Also, generate a "stable" branch of it too as that is used by test-run.sh. --- tests/Makefile.am.inc | 1 + tests/libtest.sh | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/Makefile.am.inc b/tests/Makefile.am.inc index 381580b2..adafaae1 100644 --- a/tests/Makefile.am.inc +++ b/tests/Makefile.am.inc @@ -215,6 +215,7 @@ tests/test-%.wrap: tests/runtime-repo: tests/make-test-runtime.sh flatpak rm -rf tests/runtime-repo PATH=$(abs_top_builddir):$${PATH} $(top_srcdir)/tests/make-test-runtime.sh tests/runtime-repo org.test.Platform master "" "" + PATH=$(abs_top_builddir):$${PATH} $(top_srcdir)/tests/make-test-runtime.sh tests/runtime-repo org.test.Platform stable "" "" check_DATA += tests/runtime-repo diff --git a/tests/libtest.sh b/tests/libtest.sh index 0b612d63..af5acc03 100644 --- a/tests/libtest.sh +++ b/tests/libtest.sh @@ -275,7 +275,7 @@ make_runtime () { RUNTIME_REF="runtime/org.test.Platform/$(flatpak --default-arch)/${BRANCH}" if [ ! -z "${SRC_RUNTIME_REPO:-}" ]; then RUNTIME_REPO=repos/${SRC_RUNTIME_REPO} - elif [ -f ${test_builddir}/runtime-repo/${RUNTIME_REF} ]; then + elif [ -f ${test_builddir}/runtime-repo/refs/heads/${RUNTIME_REF} ]; then RUNTIME_REPO=${test_builddir}/runtime-repo else RUNTIME_REPO=${TEST_DATA_DIR}/runtime-repo