xref: /haiku/src/tests/kits/translation/BitmapStreamTest.h (revision 90ba955b6362b3bb894b033f2bce921c4bae7096)
152a38012Sejakowatz /*****************************************************************************/
252a38012Sejakowatz // OpenBeOS Translation Kit Test
352a38012Sejakowatz //
452a38012Sejakowatz // Version: 0.1.0
552a38012Sejakowatz // Author: Brian Matzon <brian@matzon.dk>
652a38012Sejakowatz // This is the Test application for BBitmapStream
752a38012Sejakowatz //
852a38012Sejakowatz //
952a38012Sejakowatz // This application and all source files used in its construction, except
1052a38012Sejakowatz // where noted, are licensed under the MIT License, and have been written
1152a38012Sejakowatz // and are:
1252a38012Sejakowatz //
1352a38012Sejakowatz // Copyright (c) 2002 OpenBeOS Project
1452a38012Sejakowatz //
1552a38012Sejakowatz // Permission is hereby granted, free of charge, to any person obtaining a
1652a38012Sejakowatz // copy of this software and associated documentation files (the "Software"),
1752a38012Sejakowatz // to deal in the Software without restriction, including without limitation
1852a38012Sejakowatz // the rights to use, copy, modify, merge, publish, distribute, sublicense,
1952a38012Sejakowatz // and/or sell copies of the Software, and to permit persons to whom the
2052a38012Sejakowatz // Software is furnished to do so, subject to the following conditions:
2152a38012Sejakowatz //
2252a38012Sejakowatz // The above copyright notice and this permission notice shall be included
2352a38012Sejakowatz // in all copies or substantial portions of the Software.
2452a38012Sejakowatz //
2552a38012Sejakowatz // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
2652a38012Sejakowatz // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
2752a38012Sejakowatz // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
2852a38012Sejakowatz // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
2952a38012Sejakowatz // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
3052a38012Sejakowatz // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
3152a38012Sejakowatz // DEALINGS IN THE SOFTWARE.
3252a38012Sejakowatz /*****************************************************************************/
3352a38012Sejakowatz #ifndef __BITMAP_STEAM_TEST
3452a38012Sejakowatz #define __BITMAP_STEAM_TEST
3552a38012Sejakowatz 
3652a38012Sejakowatz #include <BitmapStream.h>
3752a38012Sejakowatz #include <File.h>
3852a38012Sejakowatz 
39*90ba955bSmatzon /** CppUnit support */
40*90ba955bSmatzon #include <TestCase.h>
41*90ba955bSmatzon 
42*90ba955bSmatzon class BitmapStreamTest : public BTestCase {
4352a38012Sejakowatz public:
44*90ba955bSmatzon     BitmapStreamTest(std::string name = "");
4552a38012Sejakowatz     ~BitmapStreamTest();
4652a38012Sejakowatz 
47*90ba955bSmatzon 	/* cppunit suite function prototype */
48*90ba955bSmatzon     static CppUnit::Test* Suite();
4952a38012Sejakowatz 
5052a38012Sejakowatz     //actual tests
51*90ba955bSmatzon     void InitializeTest();
52*90ba955bSmatzon 	void ConstructorTest();
53*90ba955bSmatzon 	void DetachBitmapTest();
54*90ba955bSmatzon 	void PositionTest();
55*90ba955bSmatzon 	void ReadAtTest();
56*90ba955bSmatzon 	void SeekTest();
57*90ba955bSmatzon 	void SetSizeTest();
58*90ba955bSmatzon 	void WriteAtTest();
59*90ba955bSmatzon 	void SizeTest();
6052a38012Sejakowatz private:
6152a38012Sejakowatz 	/** default roster used when performing tests */
6252a38012Sejakowatz     BTranslatorRoster* roster;
6352a38012Sejakowatz 
6452a38012Sejakowatz     /** File to read from */
6552a38012Sejakowatz     BFile* file;
6652a38012Sejakowatz };
6752a38012Sejakowatz #endif