///////////////////////////////////////////////////////////////////////////////
#ifndef _WX_TESTBSTREAM_H__
///////////////////////////////////////////////////////////////////////////////
#ifndef _WX_TESTBSTREAM_H__
CPPUNIT_TEST_SUITE_NAMED_REGISTRATION( Name, COMPOSE_TEST_NAME(Name) ); \
STREAM_IMPLEMENT_SUB_REGISTRATION_ROUTINE( Name )
CPPUNIT_TEST_SUITE_NAMED_REGISTRATION( Name, COMPOSE_TEST_NAME(Name) ); \
STREAM_IMPLEMENT_SUB_REGISTRATION_ROUTINE( Name )
///////////////////////////////////////////////////////////////////////////////
// Template class that implements a test for all base stream functions.
//
///////////////////////////////////////////////////////////////////////////////
// Template class that implements a test for all base stream functions.
//
// Note: streams not supporting this should register this test
// with CPPUNIT_TEST_FAIL instead of CPPUNIT_TEST.
CPPUNIT_ASSERT(stream_in.GetSize() != 0);
// Note: streams not supporting this should register this test
// with CPPUNIT_TEST_FAIL instead of CPPUNIT_TEST.
CPPUNIT_ASSERT(stream_in.GetSize() != 0);
// Check EOF stream state.
CPPUNIT_ASSERT_MESSAGE("EOF is not EOF?", stream_in.Eof());
// Check EOF stream state.
CPPUNIT_ASSERT_MESSAGE("EOF is not EOF?", stream_in.Eof());
// Try to Get the location in the stream...
CPPUNIT_ASSERT_EQUAL(0, stream_out.TellO());
(void)stream_out.PutC('1');
// Try to Get the location in the stream...
CPPUNIT_ASSERT_EQUAL(0, stream_out.TellO());
(void)stream_out.PutC('1');
const char *buf = "1234567890";
(void)stream_out.Write(buf, 10);
const char *buf = "1234567890";
(void)stream_out.Write(buf, 10);
CPPUNIT_ASSERT_EQUAL(pos, stream_out.TellO());
(void)stream_out.PutC('1');
CPPUNIT_ASSERT_EQUAL(6, stream_out.TellO());
CPPUNIT_ASSERT_EQUAL(pos, stream_out.TellO());
(void)stream_out.PutC('1');
CPPUNIT_ASSERT_EQUAL(6, stream_out.TellO());