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
5656393f
Kaydet (Commit)
5656393f
authored
Kas 13, 2013
tarafından
Muthu Subramanian
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Add export unit test helper to testDocumentLayout.
üst
9694f8bc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
11 deletions
+14
-11
import-tests.cxx
sd/qa/unit/import-tests.cxx
+12
-9
sdmodeltestbase.hxx
sd/qa/unit/sdmodeltestbase.hxx
+2
-2
No files found.
sd/qa/unit/import-tests.cxx
Dosyayı görüntüle @
5656393f
...
...
@@ -88,16 +88,17 @@ the test, and re-running; it should break.
*/
void
SdFiltersTest
::
testDocumentLayout
()
{
struct
{
const
char
*
pInput
,
*
pDump
;
}
aFilesToCompare
[]
=
struct
{
const
char
*
pInput
,
*
pDump
;
sal_Int32
nExportType
;
}
aFilesToCompare
[]
=
{
{
"odp/shapes-test.odp"
,
"xml/shapes-test_page"
},
{
"pptx/fdo47434-all.pptx"
,
"pptx/xml/fdo47434_page"
},
{
"n758621.ppt"
,
"xml/n758621_"
},
{
"fdo64586.ppt"
,
"xml/fdo64586_"
},
{
"n819614.pptx"
,
"xml/n819614_"
},
{
"n820786.pptx"
,
"xml/n820786_"
},
{
"n762695.pptx"
,
"xml/n762695_"
},
{
"n593612.pptx"
,
"xml/n593612_"
},
{
"odp/shapes-test.odp"
,
"xml/shapes-test_page"
,
-
1
},
{
"pptx/fdo47434-all.pptx"
,
"pptx/xml/fdo47434_page"
,
-
1
},
{
"n758621.ppt"
,
"xml/n758621_"
,
-
1
},
{
"fdo64586.ppt"
,
"xml/fdo64586_"
,
-
1
},
{
"n819614.pptx"
,
"xml/n819614_"
,
-
1
},
{
"n820786.pptx"
,
"xml/n820786_"
,
-
1
},
{
"n762695.pptx"
,
"xml/n762695_"
,
-
1
},
{
"n593612.pptx"
,
"xml/n593612_"
,
-
1
},
// { "pptx/n828390.pptx", "pptx/xml/n828390_", PPTX }, // Example
};
for
(
int
i
=
0
;
i
<
static_cast
<
int
>
(
SAL_N_ELEMENTS
(
aFilesToCompare
)
);
++
i
)
...
...
@@ -105,6 +106,8 @@ void SdFiltersTest::testDocumentLayout()
int
nUpdateMe
=
-
1
;
// index of test we want to update; supposedly only when the test is created
::
sd
::
DrawDocShellRef
xDocShRef
=
loadURL
(
getURLFromSrc
(
"/sd/qa/unit/data/"
)
+
OUString
::
createFromAscii
(
aFilesToCompare
[
i
].
pInput
)
);
if
(
aFilesToCompare
[
i
].
nExportType
>=
0
)
xDocShRef
=
saveAndReload
(
xDocShRef
,
aFilesToCompare
[
i
].
nExportType
);
compareWithShapesDump
(
xDocShRef
,
getPathFromSrc
(
"/sd/qa/unit/data/"
)
+
OUString
::
createFromAscii
(
aFilesToCompare
[
i
].
pDump
),
i
==
nUpdateMe
);
...
...
sd/qa/unit/sdmodeltestbase.hxx
Dosyayı görüntüle @
5656393f
...
...
@@ -120,10 +120,10 @@ protected:
return
xDocShRef
;
}
::
sd
::
DrawDocShellRef
saveAndReload
(
::
sd
::
DrawDocShell
*
pShell
,
sal_
uLong
nExportType
)
::
sd
::
DrawDocShellRef
saveAndReload
(
::
sd
::
DrawDocShell
*
pShell
,
sal_
Int32
nExportType
)
{
FileFormat
*
pFmt
=
&
aFileFormats
[
0
];
if
(
nExportType
<
SAL_N_ELEMENTS
(
aFileFormats
)
)
if
(
(
(
sal_uInt32
)
nExportType
)
<
SAL_N_ELEMENTS
(
aFileFormats
)
)
pFmt
=
&
aFileFormats
[
nExportType
];
OUString
aExt
=
OUString
(
"."
)
+
OUString
::
createFromAscii
(
pFmt
->
pName
);
utl
::
TempFile
aTempFile
(
OUString
(),
&
aExt
);
...
...
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