Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
462907d4
Kaydet (Commit)
462907d4
authored
Agu 12, 2012
tarafından
Markus Mohrhard
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
add simple test for ods color scale import
Change-Id: I539c6bfec17febbdd97c724fbde55b75da7700f6
üst
b2e6a571
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
0 deletions
+47
-0
colorScale.ods
sc/qa/unit/data/ods/colorScale.ods
+0
-0
subsequent_filters-test.cxx
sc/qa/unit/subsequent_filters-test.cxx
+47
-0
No files found.
sc/qa/unit/data/ods/colorScale.ods
0 → 100644
Dosyayı görüntüle @
462907d4
File added
sc/qa/unit/subsequent_filters-test.cxx
Dosyayı görüntüle @
462907d4
...
...
@@ -130,6 +130,10 @@ public:
void
testRepeatedColumnsODS
();
void
testDataValidityODS
();
void
testColorScale
();
void
testDataBar
();
void
testCondFormat
();
//change this test file only in excel and not in calc
void
testSharedFormulaXLSX
();
void
testCellValueXLSX
();
...
...
@@ -170,6 +174,10 @@ public:
CPPUNIT_TEST
(
testCellValueXLSX
);
CPPUNIT_TEST
(
testControlImport
);
CPPUNIT_TEST
(
testColorScale
);
CPPUNIT_TEST
(
testDataBar
);
CPPUNIT_TEST
(
testCondFormat
);
//disable testPassword on MacOSX due to problems with libsqlite3
//also crashes on DragonFly due to problems with nss/nspr headers
#if !defined(MACOSX) && !defined(DRAGONFLY) && !defined(WNT)
...
...
@@ -1172,6 +1180,45 @@ void ScFiltersTest::testControlImport()
xDocSh
->
DoClose
();
}
void
ScFiltersTest
::
testColorScale
()
{
const
rtl
::
OUString
aFileNameBase
(
RTL_CONSTASCII_USTRINGPARAM
(
"colorScale."
));
rtl
::
OUString
aFileExtension
(
aFileFormats
[
ODS
].
pName
,
strlen
(
aFileFormats
[
ODS
].
pName
),
RTL_TEXTENCODING_UTF8
);
rtl
::
OUString
aFilterName
(
aFileFormats
[
ODS
].
pFilterName
,
strlen
(
aFileFormats
[
ODS
].
pFilterName
),
RTL_TEXTENCODING_UTF8
)
;
rtl
::
OUString
aFileName
;
createFileURL
(
aFileNameBase
,
aFileExtension
,
aFileName
);
rtl
::
OUString
aFilterType
(
aFileFormats
[
ODS
].
pTypeName
,
strlen
(
aFileFormats
[
ODS
].
pTypeName
),
RTL_TEXTENCODING_UTF8
);
std
::
cout
<<
aFileFormats
[
ODS
].
pName
<<
" Test"
<<
std
::
endl
;
ScDocShellRef
xDocSh
=
load
(
aFilterName
,
aFileName
,
rtl
::
OUString
(),
aFilterType
,
aFileFormats
[
ODS
].
nFormatType
);
CPPUNIT_ASSERT_MESSAGE
(
"Failed to load colorScale.ods"
,
xDocSh
.
Is
());
ScDocument
*
pDoc
=
xDocSh
->
GetDocument
();
const
ScPatternAttr
*
pPattern
=
pDoc
->
GetPattern
(
1
,
1
,
0
);
sal_uLong
nIndex
=
static_cast
<
const
SfxUInt32Item
&>
(
pPattern
->
GetItem
(
ATTR_CONDITIONAL
)).
GetValue
();
CPPUNIT_ASSERT
(
nIndex
);
ScConditionalFormatList
*
pCondFormatList
=
pDoc
->
GetCondFormList
(
0
);
const
ScConditionalFormat
*
pFormat
=
pCondFormatList
->
GetFormat
(
nIndex
);
CPPUNIT_ASSERT
(
pFormat
);
pPattern
=
pDoc
->
GetPattern
(
1
,
5
,
0
);
nIndex
=
static_cast
<
const
SfxUInt32Item
&>
(
pPattern
->
GetItem
(
ATTR_CONDITIONAL
)).
GetValue
();
CPPUNIT_ASSERT
(
nIndex
);
pFormat
=
pCondFormatList
->
GetFormat
(
nIndex
);
CPPUNIT_ASSERT
(
pFormat
);
}
void
ScFiltersTest
::
testDataBar
()
{
}
void
ScFiltersTest
::
testCondFormat
()
{
}
ScFiltersTest
::
ScFiltersTest
()
:
m_aBaseString
(
RTL_CONSTASCII_USTRINGPARAM
(
"/sc/qa/unit/data"
))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment