All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] run-tests.sh: Use piglit names when listing available tests
@ 2017-10-24 10:40 Petri Latvala
  2017-10-24 12:18 ` Arkadiusz Hiler
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Petri Latvala @ 2017-10-24 10:40 UTC (permalink / raw)
  To: intel-gfx; +Cc: Tomi Sarvela

List the available tests with piglit instead of by hand. This solves
naming inconsistencies (piglit throwing caps away) as seen by
cibuglog, and makes the listing code simpler.

The format of the listing changes from

 test-binary/subtest-name

to

 igt@test-binary@subtest-name

but so far nothing has been able to directly consume run-tests.sh -l
output. The piglit format is directly consumable by piglit --test-list, and thus
by run-tests.sh -T.

Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Tomi Sarvela <tomi.p.sarvela@intel.com>
Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
---

This patch cannot be merged without explicit confirmation from Tomi
and Arek that the CI side is ready for this. Today, this will break
sharded runs.


scripts/run-tests.sh | 22 ++++++----------------
 1 file changed, 6 insertions(+), 16 deletions(-)

diff --git a/scripts/run-tests.sh b/scripts/run-tests.sh
index a28dd876..acd2ae2f 100755
--- a/scripts/run-tests.sh
+++ b/scripts/run-tests.sh
@@ -40,8 +40,6 @@ if [ ! -f "$IGT_TEST_ROOT/test-list.txt" ]; then
 	exit 1
 fi
 
-TEST_LIST=`cat "$IGT_TEST_ROOT/test-list.txt" | sed -e '/TESTLIST/d' -e 's/ /\n/g'`
-
 function download_piglit {
 	git clone git://anongit.freedesktop.org/piglit "$ROOT/piglit"
 }
@@ -70,24 +68,11 @@ function print_help {
 	echo "Useful patterns for test filtering are described in the API documentation."
 }
 
-function list_tests {
-	for test in $TEST_LIST; do
-		SUBTESTS=`"$IGT_TEST_ROOT/$test" --list-subtests`
-		if [ -z "$SUBTESTS" ]; then
-			echo "$test"
-		else
-			for subtest in $SUBTESTS; do
-				echo "$test/$subtest"
-			done
-		fi
-	done
-}
-
 while getopts ":dhlr:st:T:vx:Rn" opt; do
 	case $opt in
 		d) download_piglit; exit ;;
 		h) print_help; exit ;;
-		l) list_tests; exit ;;
+		l) LIST_TESTS="true" ;;
 		r) RESULTS="$OPTARG" ;;
 		s) SUMMARY="html" ;;
 		t) FILTER="$FILTER -t $OPTARG" ;;
@@ -125,6 +110,11 @@ if [ ! -x "$PIGLIT" ]; then
 	exit 1
 fi
 
+if [ "x$LIST_TESTS" != "x" ]; then
+	IGT_TEST_ROOT="$IGT_TEST_ROOT" IGT_CONFIG_PATH="$IGT_CONFIG_PATH" "$PIGLIT" print-cmd --format "{name}" igt
+	exit
+fi
+
 if [ "x$RESUME" != "x" ]; then
 	sudo IGT_TEST_ROOT="$IGT_TEST_ROOT" IGT_CONFIG_PATH="$IGT_CONFIG_PATH" "$PIGLIT" resume "$RESULTS" $NORETRY
 else
-- 
2.14.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-10-30 10:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-24 10:40 [PATCH i-g-t] run-tests.sh: Use piglit names when listing available tests Petri Latvala
2017-10-24 12:18 ` Arkadiusz Hiler
2017-10-24 12:45   ` Tomi Sarvela
2017-10-30  8:55 ` ✗ Fi.CI.BAT: failure for " Patchwork
2017-10-30  9:40 ` ✓ Fi.CI.BAT: success " Patchwork
2017-10-30 10:30   ` Arkadiusz Hiler
2017-10-30 10:27 ` ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.