[cairo-commit] test/get-path-extents.c
Andrea Canciani
ranma42 at kemper.freedesktop.org
Mon Sep 10 14:16:49 PDT 2012
test/get-path-extents.c | 8 ++++++++
1 file changed, 8 insertions(+)
New commits:
commit 93774ac0348df04c3fa84f5bc01fe35c87a62089
Author: Andrea Canciani <ranma42 at gmail.com>
Date: Wed Sep 5 17:52:50 2012 +0200
test: Add degenerate closed path case to get-path-extents
This is a testcase to ensure that we do not regress
https://bugs.freedesktop.org/show_bug.cgi?id=54549 (which is already
fixed by b0c466e27afcec230b2c9436eeb924c05123a544).
diff --git a/test/get-path-extents.c b/test/get-path-extents.c
index 7d07aab..5ea2d4a 100644
--- a/test/get-path-extents.c
+++ b/test/get-path-extents.c
@@ -129,6 +129,14 @@ draw (cairo_t *cr, int width, int height)
cairo_new_path (cr2);
cairo_move_to (cr2, 200, 400);
+ cairo_close_path (cr2);
+ phase = "Degenerate closed path";
+ errors += !check_extents (ctx, phase, cr2, FILL, EQUALS, 0, 0, 0, 0);
+ errors += !check_extents (ctx, phase, cr2, STROKE, EQUALS, 0, 0, 0, 0);
+ errors += !check_extents (ctx, phase, cr2, PATH, EQUALS, 200, 400, 0, 0);
+
+ cairo_new_path (cr2);
+ cairo_move_to (cr2, 200, 400);
cairo_rel_line_to (cr2, 0., 0.);
phase = "Degenerate line";
errors += !check_extents (ctx, phase, cr2, FILL, EQUALS, 0, 0, 0, 0);
More information about the cairo-commit
mailing list