From 2abc107b24f73b8c4664189c34196d9a27a3e339 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Sat, 16 Jun 2018 18:05:00 +0200 Subject: Port the rest of the unittests to DGUnit and remove the CppUnit dependency. --- test/paintertest.cc | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'test/paintertest.cc') diff --git a/test/paintertest.cc b/test/paintertest.cc index 75f97fa..c6e8615 100644 --- a/test/paintertest.cc +++ b/test/paintertest.cc @@ -24,7 +24,7 @@ * along with DrumGizmo; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#include +#include "dgunit.h" #include "../plugingui/canvas.h" #include "../plugingui/painter.h" @@ -49,16 +49,14 @@ private: }; class PainterTest - : public CppUnit::TestFixture + : public DGUnit { - CPPUNIT_TEST_SUITE(PainterTest); - CPPUNIT_TEST(testDrawImage); - CPPUNIT_TEST(testDrawText); - CPPUNIT_TEST_SUITE_END(); - public: - void setUp() {} - void tearDown() {} + PainterTest() + { + DGUNIT_TEST(PainterTest::testDrawImage); + DGUNIT_TEST(PainterTest::testDrawText); + } void testDrawImage() { @@ -158,4 +156,4 @@ public: }; // Registers the fixture into the 'registry' -CPPUNIT_TEST_SUITE_REGISTRATION(PainterTest); +static PainterTest test; -- cgit v1.2.3