Kaydet (Commit) 585b0800 authored tarafından Kohei Yoshida's avatar Kohei Yoshida

calling loadDoc is simpler.

Change-Id: I6a507825252f316c8106ea4b856bf166a010c15b
üst 08706f37
......@@ -1328,19 +1328,7 @@ void ScFiltersTest::testPasswordOld()
void ScFiltersTest::testControlImport()
{
const rtl::OUString aFileNameBase(RTL_CONSTASCII_USTRINGPARAM("singlecontrol."));
rtl::OUString aFileExtension(aFileFormats[XLSX].pName, strlen(aFileFormats[XLSX].pName), RTL_TEXTENCODING_UTF8 );
rtl::OUString aFilterName(aFileFormats[XLSX].pFilterName, strlen(aFileFormats[XLSX].pFilterName), RTL_TEXTENCODING_UTF8) ;
rtl::OUString aFileName;
createFileURL(aFileNameBase, aFileExtension, aFileName);
rtl::OUString aFilterType(aFileFormats[XLSX].pTypeName, strlen(aFileFormats[XLSX].pTypeName), RTL_TEXTENCODING_UTF8);
std::cout << aFileFormats[XLSX].pName << " Test" << std::endl;
unsigned int nFormatType = aFileFormats[XLSX].nFormatType;
unsigned int nClipboardId = nFormatType ? SFX_FILTER_IMPORT | SFX_FILTER_USESOPTIONS : 0;
ScDocShellRef xDocSh = load(aFilterName, aFileName, rtl::OUString(), aFilterType,
nFormatType, nClipboardId, SOFFICE_FILEFORMAT_CURRENT);
ScDocShellRef xDocSh = loadDoc("singlecontrol.", XLSX);
CPPUNIT_ASSERT_MESSAGE("Failed to load cell-value.xlsx", xDocSh.Is());
uno::Reference< frame::XModel > xModel = xDocSh->GetModel();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment