From c2e220ff995cd4976c65bab1c34172dd4b303d1a Mon Sep 17 00:00:00 2001 From: Jaskaran Singh Date: Sat, 6 Aug 2016 13:33:42 +0530 Subject: Add test for cell align in orcus interface(currently disabled) Change-Id: Icbb139cc520e4afd84986d245fab5f157431fc4e --- sc/qa/unit/data/xml/styles.xml | 2 +- sc/qa/unit/subsequent_filters-test.cxx | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/sc/qa/unit/data/xml/styles.xml b/sc/qa/unit/data/xml/styles.xml index ef9c337ee766..b481219f5dd4 100644 --- a/sc/qa/unit/data/xml/styles.xml +++ b/sc/qa/unit/data/xml/styles.xml @@ -27,7 +27,7 @@ - + diff --git a/sc/qa/unit/subsequent_filters-test.cxx b/sc/qa/unit/subsequent_filters-test.cxx index 2bdf722c620b..6562b4ab2b90 100644 --- a/sc/qa/unit/subsequent_filters-test.cxx +++ b/sc/qa/unit/subsequent_filters-test.cxx @@ -2860,6 +2860,24 @@ void ScFiltersTest::testOrcusODSStyleInterface() pCrossedOutItem = static_cast(pItem); CPPUNIT_ASSERT_MESSAGE("Style Name9 :Error with Strikeout", pCrossedOutItem->GetStrikeout() == STRIKEOUT_SLASH); + /* Test for Style Name "10" + * Has ver align, and hor align + */ + /* + pStyleSheet = pStyleSheetPool->FindCaseIns("Name10", SfxStyleFamily::Para); + CPPUNIT_ASSERT_MESSAGE("Style Name10 : Doesn't have Attribute hor justify, but it should have.", + pStyleSheet->GetItemSet().HasItem(ATTR_HOR_JUSTIFY, &pItem)); + + const SvxHorJustifyItem* pHorJustify = static_cast(pItem); + CPPUNIT_ASSERT_MESSAGE("Style Name10 :Error with hor justify", pHorJustify->GetValue() == SVX_HOR_JUSTIFY_RIGHT); + + pStyleSheet = pStyleSheetPool->FindCaseIns("Name10", SfxStyleFamily::Para); + CPPUNIT_ASSERT_MESSAGE("Style Name10 : Doesn't have Attribute ver justify, but it should have.", + pStyleSheet->GetItemSet().HasItem(ATTR_VER_JUSTIFY, &pItem)); + + const SvxVerJustifyItem* pVerJustify = static_cast(pItem); + CPPUNIT_ASSERT_MESSAGE("Style Name10 :Error with ver justify", pVerJustify->GetValue() == SVX_VER_JUSTIFY_CENTER); + */ } #endif -- cgit