From ba91106b9500d895aee1c60a68a24c752155611d Mon Sep 17 00:00:00 2001 From: Tomaž Vajngerl Date: Sat, 2 Aug 2014 22:35:01 +0200 Subject: Change RectWithStylesByGroup to be same as other style tests Change-Id: Ib7b0d2e8160a938821940645ea6e6471188bcc16 --- svgio/qa/cppunit/SvgImportTest.cxx | 8 ++++-- svgio/qa/cppunit/data/RectWithStylesByGroup.svg | 34 ++++++++++++------------- 2 files changed, 23 insertions(+), 19 deletions(-) (limited to 'svgio') diff --git a/svgio/qa/cppunit/SvgImportTest.cxx b/svgio/qa/cppunit/SvgImportTest.cxx index 86784a599581..5b8392d843a8 100644 --- a/svgio/qa/cppunit/SvgImportTest.cxx +++ b/svgio/qa/cppunit/SvgImportTest.cxx @@ -72,6 +72,9 @@ void Test::tearDown() BootstrapFixture::tearDown(); } +// Attributes for an object (like rect as in this case) can be defined +// in different ways (directly with xml attributes, or with CSS styles), +// however the end result should be the same. void Test::testStyles() { Primitive2DSequence maSequenceRect = parseSvg("/svgio/qa/cppunit/data/Rect.svg"); @@ -86,8 +89,9 @@ void Test::testStyles() Primitive2DSequence maSequenceRectWithStylesByGroup = parseSvg("/svgio/qa/cppunit/data/RectWithStylesByGroup.svg"); CPPUNIT_ASSERT_EQUAL(1, (int) maSequenceRectWithStylesByGroup.getLength()); - CPPUNIT_ASSERT_EQUAL(true, (bool) arePrimitive2DSequencesEqual(maSequenceRect, maSequenceRectWithStyle)); - CPPUNIT_ASSERT_EQUAL(true, (bool) arePrimitive2DSequencesEqual(maSequenceRect, maSequenceRectWithParentStyle)); + CPPUNIT_ASSERT(arePrimitive2DSequencesEqual(maSequenceRect, maSequenceRectWithStyle)); + CPPUNIT_ASSERT(arePrimitive2DSequencesEqual(maSequenceRect, maSequenceRectWithParentStyle)); + CPPUNIT_ASSERT(arePrimitive2DSequencesEqual(maSequenceRect, maSequenceRectWithStylesByGroup)); } CPPUNIT_TEST_SUITE_REGISTRATION(Test); diff --git a/svgio/qa/cppunit/data/RectWithStylesByGroup.svg b/svgio/qa/cppunit/data/RectWithStylesByGroup.svg index 6fefdf2f53f2..0a3b1e3cd8eb 100644 --- a/svgio/qa/cppunit/data/RectWithStylesByGroup.svg +++ b/svgio/qa/cppunit/data/RectWithStylesByGroup.svg @@ -1,18 +1,18 @@ - - - - - - - - - + + + + + + + + + -- cgit v1.2.3