From: Yurii R. <yr...@us...> - 2003-02-02 06:59:14
|
Update of /cvsroot/eas-dev/eas-dev/libs/libsxmlstream/tests In directory sc8-pr-cvs1:/tmp/cvs-serv30198/libs/libsxmlstream/tests Modified Files: TextStreamTest.h Added Files: BinaryStreamTest.h Makefile.am Log Message: modified build process; moving to glib-2.2.0; pkg-config; unstable changes to `logger' component; minor changes to libsxmlstream; binarystream test added to libsxmlstream (both text and binary streams are broken now); per-platform INSTALL notes --- NEW FILE: BinaryStreamTest.h --- /* $Id: BinaryStreamTest.h,v 1.1 2003/02/02 06:59:11 yrashk Exp $ */ #ifndef _BINARYSTREAMTEST_H_ #define _BINARYSTREAMTEST_H_ #include <iostream> #include <sstream> #include <string> #include <cstring> #include <cxxtest/TestSuite.h> #include <sxmlstream.hxx> using namespace std; class BinaryStreamTest: public CxxTest::TestSuite { SXmlBinaryStream * _stream; public: void setUp() { _stream = new SXmlBinaryStream(); } void tearDown() { } void test_output() { stringstream _output(""); // Prepare structures SXmlNode top = SXmlNode::Element("test"); SXmlNode top_attr = SXmlNode::Attribute("attr","value"); top.addChild(top_attr); _stream->push(top); _output << (*_stream); TS_ASSERT_EQUALS(_output.str(), "(test (@ (attr \"value\")))"); } }; #endif /* _BINARYSTREAMTEST_H_ */ --- NEW FILE: Makefile.am --- bin_PROGRAMS = runTests runTests_SOURCES = runTests.cxx INCLUDES = -I../include runTests_LDFLAGS = -L../src/ runTests_LDADD = @GLIB_LIBS@ -lsxmlstream CLEANFILES = runTests.cxx TESTS = runTests runTests.cxx: TextStreamTest.h BinaryStreamTest.h $(top_srcdir)/../../tools/test/cxxtestgen.py --error-printer --exit-code -o runTests.cxx \ TextStreamTest.h BinaryStreamTest.h Index: TextStreamTest.h =================================================================== RCS file: /cvsroot/eas-dev/eas-dev/libs/libsxmlstream/tests/TextStreamTest.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- TextStreamTest.h 28 Jan 2003 22:36:28 -0000 1.3 +++ TextStreamTest.h 2 Feb 2003 06:59:11 -0000 1.4 @@ -1,3 +1,4 @@ +/* $Id$ */ #ifndef _TEXTSTREAMTEST_H_ #define _TEXTSTREAMTEST_H_ |