From b9161e6e332cb0279ef8616dbbce4c90b60bce15 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 3 Aug 2010 14:12:48 +0200 Subject: New tests --- mysql/template/driver.cxx | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 mysql/template/driver.cxx (limited to 'mysql/template/driver.cxx') diff --git a/mysql/template/driver.cxx b/mysql/template/driver.cxx new file mode 100644 index 0000000..76a41bb --- /dev/null +++ b/mysql/template/driver.cxx @@ -0,0 +1,46 @@ +// file : mysql/template/driver.cxx +// author : Boris Kolpackov +// copyright : Copyright (c) 2009-2010 Code Synthesis Tools CC +// license : GNU GPL v2; see accompanying LICENSE file + +// PLACE TEST DESCRIPTION HERE +// + +#include // std::auto_ptr +#include +#include + +#include +#include + +#include + +#include "test.hxx" +#include "test-odb.hxx" + +using namespace std; +using namespace odb; + +using odb::shared_ptr; + +int +main (int argc, char* argv[]) +{ + try + { + auto_ptr db (create_database (argc, argv)); + + // + // + cout << "test 001" << endl; + { + transaction t (db->begin_transaction ()); + t.commit (); + } + } + catch (const odb::exception& e) + { + cerr << e.what () << endl; + return 1; + } +} -- cgit v1.1