12#include <com/sun/star/sheet/TableFilterField2.hpp>
13#include <com/sun/star/sheet/XSheetFilterDescriptor2.hpp>
15#include <com/sun/star/uno/Reference.hxx>
16#include <com/sun/star/uno/Sequence.hxx>
18#include <cppunit/TestAssert.h>
21using namespace css::uno;
27 uno::Reference<sheet::XSheetFilterDescriptor2> xSFD(
init(), uno::UNO_QUERY_THROW);
28 uno::Sequence<sheet::TableFilterField2> aDefaultTFF = xSFD->getFilterFields2();
30 CPPUNIT_ASSERT_MESSAGE(
"Unable to get TableFilterField", !aDefaultTFF.hasElements());
32 uno::Sequence<sheet::TableFilterField2> aTFF;
35 xSFD->setFilterFields2(aTFF);
36 uno::Sequence<sheet::TableFilterField2> aNewTFF = xSFD->getFilterFields2();
37 CPPUNIT_ASSERT_MESSAGE(
"Unable to set TableFilterField", aNewTFF != aDefaultTFF);
virtual css::uno::Reference< css::uno::XInterface > init()=0
void testGetSetFilterFields2()