summaryrefslogtreecommitdiff
path: root/odb-tests/evolution/combined/driver.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'odb-tests/evolution/combined/driver.cxx')
-rw-r--r--odb-tests/evolution/combined/driver.cxx17
1 files changed, 11 insertions, 6 deletions
diff --git a/odb-tests/evolution/combined/driver.cxx b/odb-tests/evolution/combined/driver.cxx
index 88453c3..027bddd 100644
--- a/odb-tests/evolution/combined/driver.cxx
+++ b/odb-tests/evolution/combined/driver.cxx
@@ -4,21 +4,23 @@
// Combined schema evolution test.
//
-#include <memory> // std::auto_ptr
-#include <cassert>
+#include <memory> // std::unique_ptr
#include <iostream>
#include <odb/database.hxx>
#include <odb/transaction.hxx>
#include <odb/schema-catalog.hxx>
-#include <common/common.hxx>
+#include <libcommon/common.hxx>
#include "test2.hxx"
#include "test3.hxx"
#include "test2-odb.hxx"
#include "test3-odb.hxx"
+#undef NDEBUG
+#include <cassert>
+
using namespace std;
using namespace odb::core;
@@ -27,7 +29,10 @@ main (int argc, char* argv[])
{
try
{
- auto_ptr<database> db (create_database (argc, argv, false));
+ unique_ptr<database> db (create_database (argc, argv, false));
+
+ db->schema_version_table ("evo_comb_sv");
+
bool embedded (schema_catalog::exists (*db));
// 1 - base version
@@ -89,7 +94,7 @@ main (int argc, char* argv[])
{
transaction t (db->begin ());
- auto_ptr<object> p (db->load<object> ("1"));
+ unique_ptr<object> p (db->load<object> ("1"));
assert (p->ac1 == 999);
assert (!p->ac2);
@@ -126,7 +131,7 @@ main (int argc, char* argv[])
{
transaction t (db->begin ());
- auto_ptr<object> p (db->load<object> ("1"));
+ unique_ptr<object> p (db->load<object> ("1"));
// Check post-migration.
//