Commit 02ec7a70 authored by Oliver Sander's avatar Oliver Sander

Add additional render tests

The file stroke-alpha-pattern.pdf contains a third shape.
It is rendered correctly by all backends, but as the
infrastructure is in place we may as well add a quick
test for that.
parent d500783f
Pipeline #144682 passed with stage
in 3 minutes and 19 seconds
...@@ -82,6 +82,17 @@ void TestStrokeOpacity::checkStrokeOpacity() ...@@ -82,6 +82,17 @@ void TestStrokeOpacity::checkStrokeOpacity()
tolerance = 2; tolerance = 2;
QVERIFY(approximatelyEqual(pixelUpperLeftOnStroke, QColor(253,233,196,255))); QVERIFY(approximatelyEqual(pixelUpperLeftOnStroke, QColor(253,233,196,255)));
// At the upper right there is a semi-transparent stroked red square
// a) Make sure that the color is correct.
auto pixelUpperRightOnStroke = image.pixel(130,20);
tolerance = 0;
QVERIFY(approximatelyEqual(pixelUpperRightOnStroke, QColor(246,196,206,255)));
// b) Make sure that it is really stroked, not filled
auto pixelUpperRightInterior = image.pixel(130,50);
QVERIFY(approximatelyEqual(pixelUpperRightInterior, Qt::white));
} }
QTEST_GUILESS_MAIN(TestStrokeOpacity) QTEST_GUILESS_MAIN(TestStrokeOpacity)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment