diff options
author | Vicent Marti <tanoku@gmail.com> | 2011-03-16 21:35:51 +0200 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2011-03-20 21:45:06 +0200 |
commit | bb3de0c472b2d5d6b8091c190bee3db79c4b5e27 (patch) | |
tree | 6be2facd0014fff4a4769b6a6a082c722c03ad87 /tests/t11-sqlite.c | |
parent | b5c5f0f8086ee4e9bccf0703386fd5219ac380c2 (diff) | |
download | libgit2-bb3de0c472b2d5d6b8091c190bee3db79c4b5e27.tar.gz |
Thread safe cache
Diffstat (limited to 'tests/t11-sqlite.c')
-rw-r--r-- | tests/t11-sqlite.c | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/tests/t11-sqlite.c b/tests/t11-sqlite.c index 9e9d1b786..ba9065e76 100644 --- a/tests/t11-sqlite.c +++ b/tests/t11-sqlite.c @@ -23,11 +23,14 @@ * Boston, MA 02110-1301, USA. */ #include "test_lib.h" -#include "t03-data.h" + +#ifdef GIT2_SQLITE_BACKEND +#include "t03-data.h" #include "fileops.h" #include "git2/odb_backend.h" + static int cmp_objects(git_rawobj *o1, git_rawobj *o2) { if (o1->type != o2->type) @@ -41,7 +44,6 @@ static int cmp_objects(git_rawobj *o1, git_rawobj *o2) static git_odb *open_sqlite_odb(void) { -#ifdef GIT2_SQLITE_BACKEND git_odb *odb; git_odb_backend *sqlite; @@ -55,9 +57,6 @@ static git_odb *open_sqlite_odb(void) return NULL; return odb; -#else - return NULL; -#endif } #define TEST_WRITE(PTR) {\ @@ -105,7 +104,6 @@ END_TEST BEGIN_SUITE(sqlite) -#ifdef GIT2_SQLITE_BACKEND ADD_TEST(sqlite0); ADD_TEST(sqlite1); ADD_TEST(sqlite2); @@ -113,5 +111,13 @@ BEGIN_SUITE(sqlite) ADD_TEST(sqlite4); ADD_TEST(sqlite5); ADD_TEST(sqlite6); -#endif END_SUITE + +#else /* no sqlite builtin */ +BEGIN_SUITE(sqlite) + /* empty */ +END_SUITE +#endif + + + |