BinaryReader with documentation and unit tests + CppUnit

Hello Everybody!

Attached is a patch that contains the implementation, documentation, unit tests and the CppUnit library with a corresponding qmake make file.

BinaryReader will be used for parsing BitTorrent packets and later maybe rewrite the Gnutella packets to use it.

All test code is located in the Testing subdirectory. To build the test app:


$ cd calitko-0.5.4-your-branch-name
$ cd Testing
$ qmake
$ make

The built executable is named Tester (Tester.exe under Windows). If you run it you’ll see 10 tests have passed :-)

I will not commit the patch now and will wait a few days for some feedback. I hope somebody will find some time to inspect the source code of BinaryReader located in Utils/Encodings and the corresponding tests in Testing/Utils/Encodings/BinaryReaderTest.cpp. If you have ideas about further tests that will be great!

I hope you guys find the bugs now!

Regards,

Peter

Would you like to post a relpy?


This post starts a thread.
Follow-ups:
Re: BinaryReader with documentation and unit tests + CppUnit
I've just committed this patch together with the one that fixes the case of the cppunit directory in revision 57. Peter Dimov wrote: Hello Everybody! Attached is a patch that contains the (more...)
Re: BinaryReader with documentation and unit tests + CppUnit
Hi Peter I am at calitko-0.5.4 ( the base version ) and built it fine... Next I applied the patch but get the following error: ~/calitko-0.5.4/Testing> make cd cppunit && /usr/local/Trolltech/Qt-4.1.4/bin/qmake cppunit.pro -unix -o (more...)