Module: wine Branch: master Commit: 1a24d1c0f1cb22c076ee412c50f621de150ee910 URL: http://source.winehq.org/git/wine.git/?a=commit;h=1a24d1c0f1cb22c076ee412c50...
Author: Austin English austinenglish@gmail.com Date: Tue Feb 8 16:06:06 2011 -0800
gdiplus/tests: Make sure to use return values (LLVM/Clang).
---
dlls/gdiplus/tests/brush.c | 14 ++++++++++++++ 1 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/dlls/gdiplus/tests/brush.c b/dlls/gdiplus/tests/brush.c index 655d80c..5eed607 100644 --- a/dlls/gdiplus/tests/brush.c +++ b/dlls/gdiplus/tests/brush.c @@ -311,6 +311,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok, status); expectf(1.0, elements[0]); expectf(1.0, elements[1]); expectf(-1.0, elements[2]); @@ -319,6 +320,7 @@ static void test_gradientgetrect(void) expectf(-50.50, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok, status); /* vertical gradient */ pt1.X = pt1.Y = pt2.X = 0.0; pt2.Y = 10.0; @@ -336,6 +338,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok, status); expectf(0.0, elements[0]); expectf(1.0, elements[1]); expectf(-1.0, elements[2]); @@ -344,6 +347,7 @@ static void test_gradientgetrect(void) expectf(5.0, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok, status); /* horizontal gradient */ pt1.X = pt1.Y = pt2.Y = 0.0; pt2.X = 10.0; @@ -361,6 +365,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok, status); expectf(1.0, elements[0]); expectf(0.0, elements[1]); expectf(0.0, elements[2]); @@ -369,6 +374,7 @@ static void test_gradientgetrect(void) expectf(0.0, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok, status); /* slope = -1 */ pt1.X = pt1.Y = 0.0; pt2.X = 20.0; @@ -387,6 +393,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok, status); expectf(1.0, elements[0]); expectf(-1.0, elements[1]); expectf(1.0, elements[2]); @@ -395,6 +402,7 @@ static void test_gradientgetrect(void) expectf(10.0, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok, status); /* slope = 1/100 */ pt1.X = pt1.Y = 0.0; pt2.X = 100.0; @@ -413,6 +421,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok,status); expectf(1.0, elements[0]); expectf(0.01, elements[1]); expectf(-0.02, elements[2]); @@ -421,6 +430,7 @@ static void test_gradientgetrect(void) /* expectf(-1.0, elements[5]); */ } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok,status); /* zero height rect */ rectf.X = rectf.Y = 10.0; rectf.Width = 100.0; @@ -453,6 +463,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok,status); expectf(1.0, elements[0]); expectf(0.0, elements[1]); expectf(0.0, elements[2]); @@ -461,6 +472,7 @@ static void test_gradientgetrect(void) expectf(0.0, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok,status); /* passing negative Width/Height to LinearGradientModeHorizontal */ rectf.X = rectf.Y = 10.0; rectf.Width = rectf.Height = -100.0; @@ -479,6 +491,7 @@ static void test_gradientgetrect(void) if (status == Ok) { status = GdipGetMatrixElements(transform, elements); + expect(Ok,status); expectf(1.0, elements[0]); expectf(0.0, elements[1]); expectf(0.0, elements[2]); @@ -487,6 +500,7 @@ static void test_gradientgetrect(void) expectf(0.0, elements[5]); } status = GdipDeleteBrush((GpBrush*)brush); + expect(Ok,status);
GdipDeleteMatrix(transform); }