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
cc7f66dd
Kaydet (Commit)
cc7f66dd
authored
Tem 31, 2014
tarafından
Andrzej Hunt
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
LOK: add slide name retrieval test.
Change-Id: I6d2bc4dfa634223da662af6f7c9a91f06cfe7534
üst
e780c96e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
0 deletions
+23
-0
impress_slidenames.odp
libreofficekit/qa/data/impress_slidenames.odp
+0
-0
tiledrendering.cxx
libreofficekit/qa/unit/tiledrendering.cxx
+23
-0
No files found.
libreofficekit/qa/data/impress_slidenames.odp
0 → 100644
Dosyayı görüntüle @
cc7f66dd
File added
libreofficekit/qa/unit/tiledrendering.cxx
Dosyayı görüntüle @
cc7f66dd
...
...
@@ -48,6 +48,7 @@ public:
// components on the one Office instance that we retrieve.
void
runAllTests
();
void
testImpressSlideNames
(
Office
*
pOffice
);
void
testOverlay
(
Office
*
pOffice
);
CPPUNIT_TEST_SUITE
(
TiledRenderingTest
);
...
...
@@ -61,6 +62,7 @@ void TiledRenderingTest::runAllTests()
m_sLOPath
.
c_str
()
)
);
CPPUNIT_ASSERT
(
pOffice
.
get
()
);
testImpressSlideNames
(
pOffice
.
get
()
);
testOverlay
(
pOffice
.
get
()
);
}
...
...
@@ -81,6 +83,27 @@ static void dumpRGBABitmap( const OUString& rPath, const unsigned char* pBuffer,
sOutput
.
Close
();
}
void
TiledRenderingTest
::
testImpressSlideNames
(
Office
*
pOffice
)
{
const
string
sDocPath
=
m_sSrcRoot
+
"/libreofficekit/qa/data/impress_slidenames.odp"
;
const
string
sLockFile
=
m_sSrcRoot
+
"/libreofficekit/qa/data/.~lock.impress_slidenames.odp#"
;
// FIXME: this is a temporary hack: LOK will fail when trying to open a
// locked file, and since we're reusing the file for a different unit
// test it's entirely possible that an unwanted lock file will remain.
// Hence forcefully remove it here.
remove
(
sLockFile
.
c_str
()
);
scoped_ptr
<
Document
>
pDocument
(
pOffice
->
documentLoad
(
sDocPath
.
c_str
()
)
);
CPPUNIT_ASSERT
(
pDocument
->
getParts
()
==
3
);
CPPUNIT_ASSERT
(
strcmp
(
pDocument
->
getPartName
(
0
),
"TestText1"
)
==
0
);
CPPUNIT_ASSERT
(
strcmp
(
pDocument
->
getPartName
(
1
),
"TestText2"
)
==
0
);
// The third slide hasn't had a name given to it (i.e. using the rename
// context menu in Impress), thus it should (as far as I can determine)
// have a localised version of "Slide 3".
}
void
TiledRenderingTest
::
testOverlay
(
Office
*
pOffice
)
{
const
string
sDocPath
=
m_sSrcRoot
+
"/odk/examples/java/DocumentHandling/test/test1.odt"
;
...
...
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