]>
git.ipfire.org Git - thirdparty/pdns.git/blob - modules/remotebackend/test-remotebackend-post.cc
8549c1fea95b71a348a7ba18b83dcf36d40cce68
4 #include "pdns/namespaces.hh"
6 #include "pdns/dnsbackend.hh"
7 #include "pdns/dnspacket.hh"
8 #include "pdns/ueberbackend.hh"
9 #include "pdns/pdnsexception.hh"
10 #include "pdns/logger.hh"
11 #include "pdns/arguments.hh"
12 #include "pdns/json.hh"
13 #include "pdns/statbag.hh"
14 #include "pdns/packetcache.hh"
32 #define BOOST_TEST_DYN_LINK
33 #define BOOST_TEST_MAIN
34 #define BOOST_TEST_MODULE unit
36 #include <boost/test/unit_test.hpp>
37 #include <boost/assign/list_of.hpp>
39 #include <boost/tuple/tuple.hpp>
41 struct RemotebackendSetup
{
42 RemotebackendSetup() {
45 // setup minimum arguments
46 ::arg().set("module-dir")="./.libs";
48 BackendMakers().launch("remote");
49 // then get us a instance of it
50 ::arg().set("remote-connection-string")="http:url=http://localhost:62434/dns,post=1";
51 ::arg().set("remote-dnssec")="yes";
52 be
= BackendMakers().all()[0];
53 } catch (PDNSException
&ex
) {
54 BOOST_TEST_MESSAGE("Cannot start remotebackend: " << ex
.reason
);
57 ~RemotebackendSetup() { }
60 BOOST_GLOBAL_FIXTURE( RemotebackendSetup
);