diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2021-10-01 13:33:09 +1000 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2021-10-11 11:58:08 +0200 |
commit | ef4ad5f871c6ca4cfd84504752d17ed2969ff90d (patch) | |
tree | 92befe602bcc9e0ce94abba4146bcde3f46b12fc | |
parent | 545f993d86148f550a58e02c0bdefb04222ac5fe (diff) |
vcl: test OutputDevice::DrawWaveLine()
Change-Id: I31391416b1633635ce7be7b4a445008d3e5ebde6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122972
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
-rw-r--r-- | vcl/qa/cppunit/outdev.cxx | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/vcl/qa/cppunit/outdev.cxx b/vcl/qa/cppunit/outdev.cxx index 0d4d6187742e..41c4e3df8c7a 100644 --- a/vcl/qa/cppunit/outdev.cxx +++ b/vcl/qa/cppunit/outdev.cxx @@ -80,6 +80,7 @@ public: void testDrawChord(); void testDrawCheckered(); void testDrawBorder(); + void testDrawWaveLine(); CPPUNIT_TEST_SUITE(VclOutdevTest); CPPUNIT_TEST(testVirtualDevice); @@ -129,6 +130,7 @@ public: CPPUNIT_TEST(testDrawChord); CPPUNIT_TEST(testDrawCheckered); CPPUNIT_TEST(testDrawBorder); + CPPUNIT_TEST(testDrawWaveLine); CPPUNIT_TEST_SUITE_END(); }; @@ -1766,6 +1768,20 @@ void VclOutdevTest::testDrawBorder() pRectAction->GetRect()); } +void VclOutdevTest::testDrawWaveLine() +{ + ScopedVclPtrInstance<VirtualDevice> pVDev; + GDIMetaFile aMtf; + aMtf.Record(pVDev.get()); + + pVDev->SetOutputSizePixel(Size(100, 100)); + pVDev->DrawWaveLine(Point(0, 0), Point(50, 0)); + + MetaAction* pAction = aMtf.GetAction(INITIAL_SETUP_ACTION_COUNT); + CPPUNIT_ASSERT_EQUAL_MESSAGE("Not a bitmap action", MetaActionType::BMPEXSCALEPART, + pAction->GetType()); +} + CPPUNIT_TEST_SUITE_REGISTRATION(VclOutdevTest); CPPUNIT_PLUGIN_IMPLEMENT(); |