diff options
author | Eric Anholt <eric@anholt.net> | 2012-07-18 16:26:43 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2012-07-26 16:28:48 -0700 |
commit | dcb1d026f3769c1dda85198bd554954877b7e233 (patch) | |
tree | 8919a08b2ae3f966cc166388c5f71aaa2b364e00 | |
parent | d596181d7859e8bbd528006325f2100fb452a0f8 (diff) |
util: Warn when we get a window resize during an auto run.
We've got a bunch of instances of this happening intermittently during
runs with gnome-shell. Because our tests are not generally able to
handle resizes, they would show up as spurious failures that are hard
to reproduce. Instead, provide a diagnostic message and report WARN.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
-rw-r--r-- | tests/util/piglit-framework-glut.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/util/piglit-framework-glut.c b/tests/util/piglit-framework-glut.c index 690299203..9f203ef36 100644 --- a/tests/util/piglit-framework-glut.c +++ b/tests/util/piglit-framework-glut.c @@ -71,6 +71,14 @@ display(void) static void reshape(int w, int h) { + if (piglit_automatic && + (w != piglit_width || + h != piglit_height)) { + printf("Got spurious window resize in automatic run " + "(%d,%d to %d,%d)\n", piglit_width, piglit_height, w, h); + piglit_report_result(PIGLIT_WARN); + } + piglit_width = w; piglit_height = h; |