Author: cctrieloff
Date: 2007-09-08 22:02:30 -0400 (Sat, 08 Sep 2007)
New Revision: 916
Modified:
store/trunk/cpp/tests/SimpleTest.cpp
Log:
- added journal create / delete test
- need some more work to check dirs/ notes in test
Modified: store/trunk/cpp/tests/SimpleTest.cpp
===================================================================
--- store/trunk/cpp/tests/SimpleTest.cpp 2007-09-09 02:00:50 UTC (rev 915)
+++ store/trunk/cpp/tests/SimpleTest.cpp 2007-09-09 02:02:30 UTC (rev 916)
@@ -70,6 +70,7 @@
class SimpleTest : public CppUnit::TestCase
{
CPPUNIT_TEST_SUITE(SimpleTest);
+ CPPUNIT_TEST(testCreateDelete);
CPPUNIT_TEST(testEmptyRecover);
CPPUNIT_TEST(testQueueCreate);
CPPUNIT_TEST(testQueueCreateWithSettings);
@@ -114,6 +115,21 @@
//nothing to assert, just testing it doesn't blow up
}
+ void testCreateDelete()
+ {
+ BdbMessageStore store;
+ store.truncate();//make sure it is empty to begin with
+ string name("CreateDeleteQueue");
+ Queue queue(name, 0, &store, 0);
+ store.create(queue);
+ // TODO - check dir exists
+ CPPUNIT_ASSERT(queue.getPersistenceId());
+ store.destroy(queue);
+ // TODO - check dir is deleted
+
+ }
+
+
void testQueueCreate()
{
uint64_t id(0);