lkml.org 
[lkml]   [2021]   [Aug]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
Subject[PATCH 2/2] Revert "selftests: Remove KSFT_TAP_LEVEL"
From
This reverts commit f41c322f17ec4aa809222dc352439d80862c175b:
https://lore.kernel.org/linux-kselftest/20190424231236.aWGsEs-_2b6p3DpN3b_4U1xGERmHSv45uBzgjf6RIRk@z/

This patch removes nested TAP headers in kselftets TAP results and is part
of a series to alter the format of kselftest TAP results to improve
compatibility with proposed KTAP specification
(https://lore.kernel.org/linux-kselftest/CA+GJov6tdjvY9x12JsJT14qn6c7NViJxqaJk+r-K1YJzPggFDQ@mail.gmail.com/).

Signed-off-by: Rae Moar <rmoar@google.com>
Change-Id: I24e74cacfc49a90a068eb30ee1448c097de5297d
---
tools/testing/selftests/Makefile | 6 ++++++
tools/testing/selftests/kselftest/runner.sh | 1 +
2 files changed, 7 insertions(+)

diff --git a/tools/testing/selftests/Makefile b/tools/testing/selftests/Makefile
index fb010a35d61a..3bbfb83e2252 100644
--- a/tools/testing/selftests/Makefile
+++ b/tools/testing/selftests/Makefile
@@ -122,6 +122,12 @@ else
endif
endif

+# KSFT_TAP_LEVEL is used from KSFT framework to prevent nested TAP header
+# printing from tests. Applicable to run_tests case where run_tests adds
+# TAP header prior running tests and when a test program invokes another
+# with system() call. Export it here to cover override RUN_TESTS defines.
+export KSFT_TAP_LEVEL=`echo 1`
+
# Prepare for headers install
top_srcdir ?= ../../..
include $(top_srcdir)/scripts/subarch.include
diff --git a/tools/testing/selftests/kselftest/runner.sh b/tools/testing/selftests/kselftest/runner.sh
index 9b04aeb26d3a..40ce901cb38d 100644
--- a/tools/testing/selftests/kselftest/runner.sh
+++ b/tools/testing/selftests/kselftest/runner.sh
@@ -2,6 +2,7 @@
# SPDX-License-Identifier: GPL-2.0
#
# Runs a set of tests in a given subdirectory.
+export KSFT_TAP_LEVEL=1
export skip_rc=4
export timeout_rc=124
export logfile=/dev/stdout
--
2.33.0.259.gc128427fd7-goog
\
 
 \ /
  Last update: 2021-08-28 00:59    [W:0.538 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site