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
93098854
Kaydet (Commit)
93098854
authored
Eki 05, 2016
tarafından
Tamás Zolnai
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Test XLSX import of number groups
Change-Id: I12a8f301607240684676c5b50bdad0eea0923f97
üst
f1a97fab
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
0 deletions
+37
-0
shared-numgroup.xlsx
sc/qa/unit/data/xlsx/pivot-table/shared-numgroup.xlsx
+0
-0
subsequent_filters-test.cxx
sc/qa/unit/subsequent_filters-test.cxx
+37
-0
No files found.
sc/qa/unit/data/xlsx/pivot-table/shared-numgroup.xlsx
0 → 100644
Dosyayı görüntüle @
93098854
File added
sc/qa/unit/subsequent_filters-test.cxx
Dosyayı görüntüle @
93098854
...
...
@@ -202,6 +202,7 @@ public:
void
testGetPivotDataXLS
();
void
testPivotTableSharedGroupXLSX
();
void
testPivotTableSharedDateGroupXLSX
();
void
testPivotTableSharedNumGroupXLSX
();
void
testFormulaDependency
();
...
...
@@ -310,6 +311,7 @@ public:
CPPUNIT_TEST
(
testGetPivotDataXLS
);
CPPUNIT_TEST
(
testPivotTableSharedGroupXLSX
);
CPPUNIT_TEST
(
testPivotTableSharedDateGroupXLSX
);
CPPUNIT_TEST
(
testPivotTableSharedNumGroupXLSX
);
CPPUNIT_TEST
(
testRowHeightODS
);
CPPUNIT_TEST
(
testFormulaDependency
);
CPPUNIT_TEST
(
testRichTextContentODS
);
...
...
@@ -2146,6 +2148,41 @@ void ScFiltersTest::testPivotTableSharedDateGroupXLSX()
xDocSh
->
DoClose
();
}
void
ScFiltersTest
::
testPivotTableSharedNumGroupXLSX
()
{
ScDocShellRef
xDocSh
=
loadDoc
(
"pivot-table/shared-numgroup."
,
FORMAT_XLSX
);
CPPUNIT_ASSERT_MESSAGE
(
"Failed to load file"
,
xDocSh
.
Is
());
ScDocument
&
rDoc
=
xDocSh
->
GetDocument
();
// Check whether right number groups are imported for both tables
// First table
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"32674-47673"
),
rDoc
.
GetString
(
ScAddress
(
0
,
4
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"47674-62673"
),
rDoc
.
GetString
(
ScAddress
(
0
,
5
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"62674-77673"
),
rDoc
.
GetString
(
ScAddress
(
0
,
6
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"77674-92673"
),
rDoc
.
GetString
(
ScAddress
(
0
,
7
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"92674-107673"
),
rDoc
.
GetString
(
ScAddress
(
0
,
8
,
1
)));
// Second table
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"32674-47673"
),
rDoc
.
GetString
(
ScAddress
(
5
,
4
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"47674-62673"
),
rDoc
.
GetString
(
ScAddress
(
5
,
5
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"62674-77673"
),
rDoc
.
GetString
(
ScAddress
(
5
,
6
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"77674-92673"
),
rDoc
.
GetString
(
ScAddress
(
5
,
7
,
1
)));
CPPUNIT_ASSERT_EQUAL
(
OUString
(
"92674-107673"
),
rDoc
.
GetString
(
ScAddress
(
5
,
8
,
1
)));
// There should be exactly 2 pivot tables and 1 cache.
ScDPCollection
*
pDPs
=
rDoc
.
GetDPCollection
();
CPPUNIT_ASSERT_EQUAL
(
static_cast
<
size_t
>
(
2
),
pDPs
->
GetCount
());
ScDPCollection
::
SheetCaches
&
rSheetCaches
=
pDPs
->
GetSheetCaches
();
CPPUNIT_ASSERT_EQUAL
(
static_cast
<
size_t
>
(
1
),
rSheetCaches
.
size
());
const
ScDPCache
*
pCache
=
rSheetCaches
.
getExistingCache
(
ScRange
(
0
,
0
,
0
,
9
,
24
,
0
));
CPPUNIT_ASSERT_MESSAGE
(
"Pivot cache is expected for A1:J25 on the first sheet."
,
pCache
);
CPPUNIT_ASSERT_EQUAL
(
static_cast
<
size_t
>
(
10
),
pCache
->
GetFieldCount
());
xDocSh
->
DoClose
();
}
void
ScFiltersTest
::
testRowHeightODS
()
{
ScDocShellRef
xDocSh
=
loadDoc
(
"row-height-import."
,
FORMAT_ODS
);
...
...
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