summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2008-11-05 08:03:01 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2008-11-05 08:36:01 +0000
commit68309481aa9295026e3e7e6407c793f899b5e600 (patch)
tree4ce3478b788f0deb95eada707bcfecf69ce19654 /test
parent8855f9583e84ae2e6d981e21133f590bff2065ab (diff)
[test] Mark targets with is_meta?
Allow tests to skip targets based on whether they are a meta surface or not.
Diffstat (limited to 'test')
-rw-r--r--test/cairo-test.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/test/cairo-test.c b/test/cairo-test.c
index 90ca0af5..24d693dc 100644
--- a/test/cairo-test.c
+++ b/test/cairo-test.c
@@ -704,7 +704,9 @@ cairo_test_for_target (cairo_test_context_t *ctx,
xasprintf (&diff_path, "%s" CAIRO_TEST_DIFF_SUFFIX, base_path);
if (ctx->test->requirements != NULL) {
- const char *required = target->is_vector ? "target=raster" : "target=vector";
+ const char *required;
+
+ required = target->is_vector ? "target=raster" : "target=vector";
if (strstr (ctx->test->requirements, required) != NULL) {
cairo_test_log (ctx, "Error: Skipping for %s target %s\n",
target->is_vector ? "vector" : "raster",
@@ -712,6 +714,15 @@ cairo_test_for_target (cairo_test_context_t *ctx,
ret = CAIRO_TEST_UNTESTED;
goto UNWIND_STRINGS;
}
+
+ required = target->is_meta ? "target=!meta" : "target=meta";
+ if (strstr (ctx->test->requirements, required) != NULL) {
+ cairo_test_log (ctx, "Error: Skipping for %s target %s\n",
+ target->is_meta ? "meta" : "non-meta",
+ target->name);
+ ret = CAIRO_TEST_UNTESTED;
+ goto UNWIND_STRINGS;
+ }
}
width = ctx->test->width;