diff options
author | deva <deva> | 2011-02-17 11:00:14 +0000 |
---|---|---|
committer | deva <deva> | 2011-02-17 11:00:14 +0000 |
commit | db144840aba95affb3a6b5b2536059f49f0677ff (patch) | |
tree | 1c397a20aa5745c6bbb5dee6a4409f58c4542e87 /server/src/admin_export.cc | |
parent | c8651b8c89673300477ab86962640c93216ea306 (diff) |
Rewrite of all old tests to new unittest framework. Also some work on testdb; more to come...
Diffstat (limited to 'server/src/admin_export.cc')
-rw-r--r-- | server/src/admin_export.cc | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/server/src/admin_export.cc b/server/src/admin_export.cc index 9475bc3..3ec77d1 100644 --- a/server/src/admin_export.cc +++ b/server/src/admin_export.cc @@ -36,7 +36,7 @@ #include <stdlib.h> #include <pqxx/pqxx> -#include "macrotool/fieldnamescanner.h" +#include "fieldnamescanner.h" #include "configuration.h" #define SEP "\t" @@ -255,18 +255,23 @@ static std::string do_export(std::string templ, bool *ok) std::string admin_export(Environment &env, std::string templ, bool *ok) { +#ifndef WITHOUT_DB return do_export(templ, ok); +#else + return "No database available"; +#endif/* WITHOUT_DB */ } #ifdef TEST_ADMIN_EXPORT -//deps: -//cflags: -//libs: +//deps: environment.cc connectionpool.cc mutex.cc semaphore.cc configuration.cc entitylist.cc artefact.cc database.cc pracrodao.cc pracrodaotest.cc pracrodaopgsql.cc templatelist.cc macrolist.cc debug.cc macroheaderparser.cc exception.cc log.cc saxparser.cc templateheaderparser.cc versionstr.cc inotify.cc session.cc sessionserialiser.cc journal.cc journal_uploadserver.cc journal_commit.cc xml_encode_decode.cc sessionparser.cc fieldnamescanner.cc util.cc macroparser.cc templateparser.cc +//cflags: -I.. -DWITHOUT_ARTEFACT $(PQXX_CFLAGS) $(EXPAT_CFLAGS) +//libs: $(PQXX_LIBS) $(EXPAT_LIBS) #include "test.h" TEST_BEGIN; // TODO: Put some testcode here (see test.h for usable macros). +TEST_TRUE(false, "No tests yet!"); TEST_END; |