From: Mike Mason <michael.w.mason@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH i-g-t 1/1] scripts: Add capability to resume interrupted run-tests.sh session
Date: Tue, 26 Aug 2014 13:31:27 -0700 [thread overview]
Message-ID: <1409085087-6955-1-git-send-email-michael.w.mason@intel.com> (raw)
Piglit provides a 'resume' feature that can restart an interrupted
test run at the point where it stopped. This patch adds that
feature to run_tests.sh.
Signed-off-by: Mike Mason <michael.w.mason@intel.com>
---
scripts/run-tests.sh | 15 +++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/scripts/run-tests.sh b/scripts/run-tests.sh
index d0e0c67..580f777 100755
--- a/scripts/run-tests.sh
+++ b/scripts/run-tests.sh
@@ -59,6 +59,8 @@ function print_help {
echo " -v enable verbose mode"
echo " -x <regex> exclude tests that match the regular expression"
echo " (can be used more than once)"
+ echo " -R resume interrupted test where the partial results"
+ echo " are in the directory given by -r"
echo ""
echo "Useful patterns for test filtering are described in tests/NAMING-CONVENTION"
}
@@ -73,7 +75,7 @@ function list_tests {
done
}
-while getopts ":dhlr:st:vx:" opt; do
+while getopts ":dhlr:st:vx:R" opt; do
case $opt in
d) download_piglit; exit ;;
h) print_help; exit ;;
@@ -83,6 +85,7 @@ while getopts ":dhlr:st:vx:" opt; do
t) FILTER="$FILTER -t $OPTARG" ;;
v) VERBOSE="-v" ;;
x) EXCLUDE="$EXCLUDE -x $OPTARG" ;;
+ R) RESUME="true" ;;
:)
echo "Option -$OPTARG requires an argument."
exit 1
@@ -112,11 +115,15 @@ if [ ! -x "$PIGLIT" ]; then
exit 1
fi
-mkdir -p "$RESULTS"
-
-sudo IGT_TEST_ROOT="$IGT_TEST_ROOT" "$PIGLIT" run igt "$RESULTS" $VERBOSE $EXCLUDE $FILTER
+if [ "x$RESUME" != "x" ]; then
+ sudo IGT_TEST_ROOT="$IGT_TEST_ROOT" "$PIGLIT" resume "$RESULTS"
+else
+ mkdir -p "$RESULTS"
+ sudo IGT_TEST_ROOT="$IGT_TEST_ROOT" "$PIGLIT" run igt "$RESULTS" $VERBOSE $EXCLUDE $FILTER
+fi
if [ "$SUMMARY" == "html" ]; then
"$PIGLIT" summary html --overwrite "$RESULTS/html" "$RESULTS"
echo "HTML summary has been written to $RESULTS/html/index.html"
fi
+
--
1.9.1
next reply other threads:[~2014-08-26 20:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-26 20:31 Mike Mason [this message]
2014-08-29 15:44 ` [PATCH i-g-t 1/1] scripts: Add capability to resume interrupted run-tests.sh session Thomas Wood
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1409085087-6955-1-git-send-email-michael.w.mason@intel.com \
--to=michael.w.mason@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.