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
f5ef612a
Kaydet (Commit)
f5ef612a
authored
Eyl 19, 2014
tarafından
Matúš Kukan
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Use FastSaxParser directly
Change-Id: I2f21438a0ccc6bc096f3257c48e088c4114d9f45
üst
beed6cb8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
8 deletions
+7
-8
CppunitTest_sax_parser.mk
sax/CppunitTest_sax_parser.mk
+1
-1
parser.cxx
sax/qa/cppunit/parser.cxx
+6
-7
No files found.
sax/CppunitTest_sax_parser.mk
Dosyayı görüntüle @
f5ef612a
...
@@ -17,6 +17,7 @@ $(eval $(call gb_CppunitTest_use_libraries,sax_parser, \
...
@@ -17,6 +17,7 @@ $(eval $(call gb_CppunitTest_use_libraries,sax_parser, \
comphelper \
comphelper \
cppu \
cppu \
cppuhelper \
cppuhelper \
expwrap \
sal \
sal \
test \
test \
$(gb_UWINAPI) \
$(gb_UWINAPI) \
...
@@ -35,7 +36,6 @@ $(eval $(call gb_CppunitTest_use_components,sax_parser,\
...
@@ -35,7 +36,6 @@ $(eval $(call gb_CppunitTest_use_components,sax_parser,\
configmgr/source/configmgr \
configmgr/source/configmgr \
framework/util/fwk \
framework/util/fwk \
i18npool/util/i18npool \
i18npool/util/i18npool \
sax/source/expatwrap/expwrap \
sfx2/util/sfx \
sfx2/util/sfx \
ucb/source/core/ucb1 \
ucb/source/core/ucb1 \
ucb/source/ucp/file/ucpfile1 \
ucb/source/ucp/file/ucpfile1 \
...
...
sax/qa/cppunit/parser.cxx
Dosyayı görüntüle @
f5ef612a
...
@@ -10,12 +10,12 @@
...
@@ -10,12 +10,12 @@
#include <sal/config.h>
#include <sal/config.h>
#include <com/sun/star/io/Pipe.hpp>
#include <com/sun/star/io/Pipe.hpp>
#include <com/sun/star/xml/sax/FastParser.hpp>
#include <com/sun/star/xml/sax/FastToken.hpp>
#include <com/sun/star/xml/sax/FastToken.hpp>
#include <com/sun/star/xml/sax/SAXParseException.hpp>
#include <com/sun/star/xml/sax/SAXParseException.hpp>
#include <com/sun/star/xml/sax/XFast
Pars
er.hpp>
#include <com/sun/star/xml/sax/XFast
TokenHandl
er.hpp>
#include <cppuhelper/implbase1.hxx>
#include <cppuhelper/implbase1.hxx>
#include <sax/fastparser.hxx>
#include <test/bootstrapfixture.hxx>
#include <test/bootstrapfixture.hxx>
using
namespace
css
;
using
namespace
css
;
...
@@ -57,7 +57,7 @@ public:
...
@@ -57,7 +57,7 @@ public:
class
ParserTest
:
public
test
::
BootstrapFixture
class
ParserTest
:
public
test
::
BootstrapFixture
{
{
InputSource
maInput
;
InputSource
maInput
;
uno
::
Reference
<
XFastParser
>
mx
Parser
;
sax_fastparser
::
FastSaxParser
ma
Parser
;
uno
::
Reference
<
XFastDocumentHandler
>
mxDocumentHandler
;
uno
::
Reference
<
XFastDocumentHandler
>
mxDocumentHandler
;
uno
::
Reference
<
DummyTokenHandler
>
mxTokenHandler
;
uno
::
Reference
<
DummyTokenHandler
>
mxTokenHandler
;
...
@@ -78,9 +78,8 @@ private:
...
@@ -78,9 +78,8 @@ private:
void
ParserTest
::
setUp
()
void
ParserTest
::
setUp
()
{
{
test
::
BootstrapFixture
::
setUp
();
test
::
BootstrapFixture
::
setUp
();
mxParser
=
css
::
xml
::
sax
::
FastParser
::
create
(
m_xContext
);
mxTokenHandler
.
set
(
new
DummyTokenHandler
()
);
mxTokenHandler
.
set
(
new
DummyTokenHandler
()
);
m
xParser
->
setTokenHandler
(
mxTokenHandler
);
m
aParser
.
setTokenHandler
(
mxTokenHandler
);
}
}
void
ParserTest
::
tearDown
()
void
ParserTest
::
tearDown
()
...
@@ -102,13 +101,13 @@ uno::Reference< io::XInputStream > ParserTest::createStream(const OString& sInpu
...
@@ -102,13 +101,13 @@ uno::Reference< io::XInputStream > ParserTest::createStream(const OString& sInpu
void
ParserTest
::
parse
()
void
ParserTest
::
parse
()
{
{
maInput
.
aInputStream
=
createStream
(
"<a>...<b />..</a>"
);
maInput
.
aInputStream
=
createStream
(
"<a>...<b />..</a>"
);
m
xParser
->
parseStream
(
maInput
);
m
aParser
.
parseStream
(
maInput
);
maInput
.
aInputStream
=
createStream
(
"<b></a>"
);
maInput
.
aInputStream
=
createStream
(
"<b></a>"
);
bool
bException
=
false
;
bool
bException
=
false
;
try
try
{
{
m
xParser
->
parseStream
(
maInput
);
m
aParser
.
parseStream
(
maInput
);
}
}
catch
(
const
SAXParseException
&
)
catch
(
const
SAXParseException
&
)
{
{
...
...
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