All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
To: Dylan Baker <baker.dylan.c@gmail.com>,
	Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Subject: [PATCH v2 piglit] igt: Make "warn" status work again as expected, v2.
Date: Wed, 20 Apr 2016 12:56:11 +0200	[thread overview]
Message-ID: <5717604B.4040704@linux.intel.com> (raw)
In-Reply-To: <146108961320.7258.12505822330672897207@alivia>

When writing a patch that adds a igt_warn() when lockdep is unavailable
I noticed that the warn error doesn't work any more. Fix this by
monitoring
stderr, and only setting 'pass' when stderr is empty.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Dylan Baker <baker.dylan.c@gmail.com>
[mlankhorst: Changed to not use len over a potentially large string in
response to review comments.]
Reviewed-by: Dylan Baker <baker.dylan.c@gmail.com>
---
I don't have commit rights to piglit, so have a tested patch. :-)

 tests/igt.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tests/igt.py b/tests/igt.py
index 7ebb03646b50..132cfa0c8808 100644
--- a/tests/igt.py
+++ b/tests/igt.py
@@ -115,7 +115,10 @@ class IGTTest(Test):
         super(IGTTest, self).interpret_result()
 
         if self.result.returncode == 0:
-            self.result.result = 'pass'
+            if not self.result.err:
+                self.result.result = 'pass'
+            else:
+                self.result.result = 'warn'
         elif self.result.returncode == 77:
             self.result.result = 'skip'
         elif self.result.returncode == 78:
-- 
2.1.0


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

      reply	other threads:[~2016-04-20 10:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-19 13:33 [PATCH piglit] igt: Make "warn" status work again as expected Maarten Lankhorst
2016-04-19 18:13 ` Dylan Baker
2016-04-20 10:56   ` Maarten Lankhorst [this message]

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=5717604B.4040704@linux.intel.com \
    --to=maarten.lankhorst@linux.intel.com \
    --cc=baker.dylan.c@gmail.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.