#define CATCH_CONFIG_RUNNER
#include "./catch.hpp"
#include "./ReQL.hpp"

int
main(int argc, char **argv) {
  int result = Catch::Session().run(argc, argv);

  ReQL::Connection conn;

  ReQL::wait({})
  .funcall({
    ReQL::func({
      1.0,
      ReQL::db({std::string("rethinkdb")})
      .table({std::string("db_config")})
      .delete_({})
    })
  }).run(conn).toVector().clear();

  conn.close();

  return result;
}

#define CATCH_CONFIG_MAIN
#include "./catch.hpp"

--- 
+++ 
@@ -1,2 +1,24 @@
-#define CATCH_CONFIG_MAIN
+#define CATCH_CONFIG_RUNNER
 #include "./catch.hpp"
+#include "./ReQL.hpp"
+
+int
+main(int argc, char **argv) {
+  int result = Catch::Session().run(argc, argv);
+
+  ReQL::Connection conn;
+
+  ReQL::wait({})
+  .funcall({
+    ReQL::func({
+      1.0,
+      ReQL::db({std::string("rethinkdb")})
+      .table({std::string("db_config")})
+      .delete_({})
+    })
+  }).run(conn).toVector().clear();
+
+  conn.close();
+
+  return result;
+}
Add cleanup to the entire database on test exit.
