summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2017-01-01 21:59:08 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2017-01-01 21:59:08 +0000
commit435f10040f68d02c023b3ad2d6dbfc6e964e20e7 (patch)
tree46ed62a79bf13314456d2d340e1a909935f610e9
parentAdd hash to base command options (diff)
downloadlibdbpp-435f10040f68d02c023b3ad2d6dbfc6e964e20e7.tar.bz2
libdbpp-435f10040f68d02c023b3ad2d6dbfc6e964e20e7.tar.xz
libdbpp-435f10040f68d02c023b3ad2d6dbfc6e964e20e7.zip
Use connection plugin resolver for mock providers
-rw-r--r--libdbpp/mockDatabase.cpp1
-rw-r--r--libdbpp/unittests/testMock.cpp2
2 files changed, 2 insertions, 1 deletions
diff --git a/libdbpp/mockDatabase.cpp b/libdbpp/mockDatabase.cpp
index 15bfe12..5e78ca1 100644
--- a/libdbpp/mockDatabase.cpp
+++ b/libdbpp/mockDatabase.cpp
@@ -18,6 +18,7 @@ namespace AdHoc {
}
INSTANTIATEPLUGINOF(DB::MockDatabase);
INSTANTIATEFACTORY(DB::MockDatabase, const std::string &, const std::string &, const std::vector<boost::filesystem::path> &);
+PLUGINRESOLVER(DB::MockDatabaseFactory, DB::Connection::resolvePlugin);
namespace DB {
diff --git a/libdbpp/unittests/testMock.cpp b/libdbpp/unittests/testMock.cpp
index add0720..9a3eba6 100644
--- a/libdbpp/unittests/testMock.cpp
+++ b/libdbpp/unittests/testMock.cpp
@@ -11,7 +11,7 @@ BOOST_AUTO_TEST_CASE( noFactory )
{
BOOST_REQUIRE_THROW({
DB::MockDatabaseFactory::get("not-found");
- }, AdHoc::NoSuchPluginException);
+ }, AdHoc::LoadLibraryException);
}
BOOST_AUTO_TEST_CASE( mockFactory )