Started making the library sort-of-buildable
This commit is contained in:
parent
221f0c8ef8
commit
ccd7cc30ef
55 changed files with 461 additions and 304 deletions
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysAutoTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysBasicTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysMultiTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysObjectsTest : public CppUnit::TestFixture
|
||||
|
@ -201,13 +201,12 @@ void swap( T_Test& lhs , T_Test& rhs )
|
|||
|
||||
} // namespace
|
||||
|
||||
namespace lw {
|
||||
M_DECLARE_COMPARATOR( T_Test );
|
||||
namespace ebcl { M_DECLARE_COMPARATOR( T_Test ); }
|
||||
|
||||
M_DEFINE_COMPARATOR( T_Test )
|
||||
{
|
||||
return T_Comparator< uint32_t >::compare( a.serial , b.serial );
|
||||
}
|
||||
} // namespace lw
|
||||
|
||||
void ArraysObjectsTest::tearDown( )
|
||||
{
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysStaticBasicTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Arrays.hh>
|
||||
#include <ebcl/Arrays.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ArraysStaticObjectsTest : public CppUnit::TestFixture
|
||||
|
@ -179,13 +179,11 @@ void swap( T_TestObject_& lhs , T_TestObject_& rhs )
|
|||
|
||||
} // namespace
|
||||
|
||||
namespace lw {
|
||||
M_DECLARE_COMPARATOR( T_TestObject_ );
|
||||
namespace ebcl { M_DECLARE_COMPARATOR( T_TestObject_ ); }
|
||||
M_DEFINE_COMPARATOR( T_TestObject_ )
|
||||
{
|
||||
return T_Comparator< uint32_t >::compare( a.serial , b.serial );
|
||||
}
|
||||
} // namespace lw
|
||||
|
||||
void ArraysStaticObjectsTest::tearDown( )
|
||||
{
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
#include <lw/lib/Utilities.hh>
|
||||
#include <ebcl/Utilities.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
/* - ComputeHashTest ---------------------------------------------------{{{-*/
|
||||
/* - ComputeHashTest -------------------------------------------------------*/
|
||||
|
||||
class ComputeHashTest : public CppUnit::TestFixture
|
||||
{
|
||||
CPPUNIT_TEST_SUITE( ComputeHashTest );
|
||||
|
@ -25,7 +26,7 @@ public:
|
|||
|
||||
CPPUNIT_TEST_SUITE_REGISTRATION( ComputeHashTest );
|
||||
|
||||
void ComputeHashTest::testInt8( ) // {{{
|
||||
void ComputeHashTest::testInt8( )
|
||||
{
|
||||
const uint8_t t8u = 1;
|
||||
const int8_t t8su = 1 , t8ss = -1;
|
||||
|
@ -34,8 +35,7 @@ void ComputeHashTest::testInt8( ) // {{{
|
|||
CPPUNIT_ASSERT_EQUAL( uint32_t( 0xff ) , ComputeHash( t8ss ) );
|
||||
}
|
||||
|
||||
// }}}
|
||||
void ComputeHashTest::testInt16( ) // {{{
|
||||
void ComputeHashTest::testInt16( )
|
||||
{
|
||||
const uint16_t t16u = 1;
|
||||
const int16_t t16su = 1, t16ss = -1;
|
||||
|
@ -44,8 +44,7 @@ void ComputeHashTest::testInt16( ) // {{{
|
|||
CPPUNIT_ASSERT_EQUAL( uint32_t( 0xffff ) , ComputeHash( t16ss ) );
|
||||
}
|
||||
|
||||
// }}}
|
||||
void ComputeHashTest::testInt32( ) // {{{
|
||||
void ComputeHashTest::testInt32( )
|
||||
{
|
||||
uint32_t t32u = 1;
|
||||
int32_t t32su = 1, t32ss = -1;
|
||||
|
@ -54,8 +53,7 @@ void ComputeHashTest::testInt32( ) // {{{
|
|||
CPPUNIT_ASSERT_EQUAL( uint32_t( 0xffffffff ) , ComputeHash( t32ss ) );
|
||||
}
|
||||
|
||||
// }}}
|
||||
void ComputeHashTest::testInt64( ) // {{{
|
||||
void ComputeHashTest::testInt64( )
|
||||
{
|
||||
uint64_t t64u = 0x100000010L;
|
||||
int64_t t64s = -1;
|
||||
|
@ -63,8 +61,7 @@ void ComputeHashTest::testInt64( ) // {{{
|
|||
CPPUNIT_ASSERT_EQUAL( uint32_t( 0 ) , ComputeHash( t64s ) );
|
||||
}
|
||||
|
||||
// }}}
|
||||
void ComputeHashTest::testStructDefault( ) // {{{
|
||||
void ComputeHashTest::testStructDefault( )
|
||||
{
|
||||
struct T_Test_ {
|
||||
uint8_t meh[ 16 ];
|
||||
|
@ -77,7 +74,3 @@ void ComputeHashTest::testStructDefault( ) // {{{
|
|||
CPPUNIT_ASSERT_EQUAL( uint32_t( HashData( test.meh , 16 ) ) ,
|
||||
ComputeHash( test ) );
|
||||
}
|
||||
|
||||
// }}}
|
||||
|
||||
/*------------------------------------------------------------------------}}}-*/
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/HashIndex.hh>
|
||||
#include <ebcl/HashIndex.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class HashIndexTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/HashTables.hh>
|
||||
#include <ebcl/HashTables.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class KeyValueTableTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
TESTS = \
|
||||
alloc-pool \
|
||||
buffers \
|
||||
ptr-owned \
|
||||
ptr-shared \
|
||||
ptr-weak \
|
||||
|
@ -17,37 +15,41 @@ TESTS = \
|
|||
hash-index \
|
||||
key-value-table \
|
||||
object-table \
|
||||
ring-buffer \
|
||||
strings \
|
||||
strings-iterator \
|
||||
strings-storage \
|
||||
strings-builder \
|
||||
binary-reader \
|
||||
binary-writer \
|
||||
stream-file-input \
|
||||
srd-bin-reader \
|
||||
srd-bin-writer \
|
||||
srd-lexer \
|
||||
srd-text-writer \
|
||||
srd-mem-target \
|
||||
srd-parser \
|
||||
srd-parser-defs \
|
||||
srd-parser-cfg \
|
||||
srd-preproc-core \
|
||||
srd-preproc-cmd-core \
|
||||
srd-preproc-cmd-variables \
|
||||
srd-preproc-cmd-functions \
|
||||
srd-preproc-cmd-macros \
|
||||
srd-preproc-cmd-introspect \
|
||||
srd-preproc-cmd-compare \
|
||||
srd-preproc-cmd-casts \
|
||||
srd-preproc-cmd-arithmetic \
|
||||
srd-preproc-cmd-logic \
|
||||
srd-preproc-cmd-strings \
|
||||
srd-preproc-cmd-misc \
|
||||
srd-preproc-cmd-input \
|
||||
srd-preproc-tracking \
|
||||
log-data \
|
||||
console-text \
|
||||
console-edit \
|
||||
vfs
|
||||
|
||||
#TESTS = \
|
||||
# alloc-pool \
|
||||
# buffers \
|
||||
# ring-buffer \
|
||||
# strings \
|
||||
# strings-iterator \
|
||||
# strings-storage \
|
||||
# strings-builder \
|
||||
# binary-reader \
|
||||
# binary-writer \
|
||||
# stream-file-input \
|
||||
# srd-bin-reader \
|
||||
# srd-bin-writer \
|
||||
# srd-lexer \
|
||||
# srd-text-writer \
|
||||
# srd-mem-target \
|
||||
# srd-parser \
|
||||
# srd-parser-defs \
|
||||
# srd-parser-cfg \
|
||||
# srd-preproc-core \
|
||||
# srd-preproc-cmd-core \
|
||||
# srd-preproc-cmd-variables \
|
||||
# srd-preproc-cmd-functions \
|
||||
# srd-preproc-cmd-macros \
|
||||
# srd-preproc-cmd-introspect \
|
||||
# srd-preproc-cmd-compare \
|
||||
# srd-preproc-cmd-casts \
|
||||
# srd-preproc-cmd-arithmetic \
|
||||
# srd-preproc-cmd-logic \
|
||||
# srd-preproc-cmd-strings \
|
||||
# srd-preproc-cmd-misc \
|
||||
# srd-preproc-cmd-input \
|
||||
# srd-preproc-tracking \
|
||||
# log-data \
|
||||
# console-text \
|
||||
# console-edit \
|
||||
# vfs
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/HashTables.hh>
|
||||
#include <ebcl/HashTables.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class ObjectTableTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Types.hh>
|
||||
#include <ebcl/Types.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class OptionalTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Pointers.hh>
|
||||
#include <ebcl/Pointers.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class OwnPointerTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Pointers.hh>
|
||||
#include <ebcl/Pointers.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class SharedPointerTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Pointers.hh>
|
||||
#include <ebcl/Pointers.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class WeakPointerTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Types.hh>
|
||||
#include <ebcl/Types.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class UnionTest : public CppUnit::TestFixture
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include <lw/lib/Types.hh>
|
||||
#include <ebcl/Types.hh>
|
||||
#include <cppunit/extensions/HelperMacros.h>
|
||||
using namespace lw;
|
||||
using namespace ebcl;
|
||||
|
||||
|
||||
class VariantTest : public CppUnit::TestFixture
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue