summaryrefslogtreecommitdiff
path: root/src/backenddb/test_merchantdb.c
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2016-11-25 16:54:11 +0100
committerFlorian Dold <florian.dold@gmail.com>2016-11-25 16:54:11 +0100
commite3e4043ffa294f41e57c84927ea4267b2ded756b (patch)
tree210e82c31358d1c4822200a5342f588003cdcb85 /src/backenddb/test_merchantdb.c
parentced99137fe6141e65b65990348bed131e4dbba51 (diff)
downloadmerchant-e3e4043ffa294f41e57c84927ea4267b2ded756b.tar.gz
merchant-e3e4043ffa294f41e57c84927ea4267b2ded756b.tar.bz2
merchant-e3e4043ffa294f41e57c84927ea4267b2ded756b.zip
skip test cases when plugin can't be loaded due to missing DB
Diffstat (limited to 'src/backenddb/test_merchantdb.c')
-rw-r--r--src/backenddb/test_merchantdb.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/backenddb/test_merchantdb.c b/src/backenddb/test_merchantdb.c
index 334dd422..f67b0f7d 100644
--- a/src/backenddb/test_merchantdb.c
+++ b/src/backenddb/test_merchantdb.c
@@ -301,9 +301,21 @@ run (void *cls)
struct GNUNET_TIME_Absolute fake_now;
/* Data for 'store_payment()' */
- FAILIF (NULL == (plugin = TALER_MERCHANTDB_plugin_load (cfg)));
- (void) plugin->drop_tables (plugin->cls);
- FAILIF (GNUNET_OK != plugin->initialize (plugin->cls));
+ if (NULL == (plugin = TALER_MERCHANTDB_plugin_load (cfg)))
+ {
+ result = 77;
+ return;
+ }
+ if (GNUNET_OK != plugin->drop_tables (plugin->cls))
+ {
+ result = 77;
+ return;
+ }
+ if (GNUNET_OK != plugin->initialize (plugin->cls))
+ {
+ result = 77;
+ return;
+ }
/* Prepare data for 'store_payment()' */
RND_BLK (&h_contract);