[libgda] Revert "Test: Removes unused variable"
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgda] Revert "Test: Removes unused variable"
- Date: Sun, 31 Jan 2021 01:45:23 +0000 (UTC)
commit 189243214fbc4bcf6e1a1675128cb06eb4f43ed3
Author: Daniel Espinosa <esodan gmail com>
Date: Sat Jan 30 19:43:41 2021 -0600
Revert "Test: Removes unused variable"
This reverts commit 821ebf4fcf66d3c631c64cb0bbddf1b1594694c8.
tests/providers/check_mysql.c | 9 +++++++--
tests/providers/check_postgres.c | 1 +
tests/providers/check_sqlcipher.c | 9 +++++++--
tests/providers/check_sqlite.c | 9 +++++++--
tests/providers/prov-test-common.c | 1 +
5 files changed, 23 insertions(+), 6 deletions(-)
---
diff --git a/tests/providers/check_mysql.c b/tests/providers/check_mysql.c
index 53e46a243..a8462830e 100644
--- a/tests/providers/check_mysql.c
+++ b/tests/providers/check_mysql.c
@@ -23,6 +23,7 @@
extern GdaProviderInfo *pinfo;
extern GdaConnection *cnc;
+extern gboolean params_provided;
int
main (G_GNUC_UNUSED int argc, G_GNUC_UNUSED char **argv)
@@ -65,7 +66,11 @@ main (G_GNUC_UNUSED int argc, G_GNUC_UNUSED char **argv)
number_failed += prov_test_common_clean ();
}
- g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
- return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ if (! params_provided)
+ return EXIT_SUCCESS;
+ else {
+ g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
+ return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ }
}
diff --git a/tests/providers/check_postgres.c b/tests/providers/check_postgres.c
index 81a2c4713..fef2e32bb 100644
--- a/tests/providers/check_postgres.c
+++ b/tests/providers/check_postgres.c
@@ -28,6 +28,7 @@
extern GdaProviderInfo *pinfo;
extern GdaConnection *cnc;
+extern gboolean params_provided;
extern gboolean fork_tests;
//static int test_timestamp_change_format (void);
diff --git a/tests/providers/check_sqlcipher.c b/tests/providers/check_sqlcipher.c
index 971a7b661..5b9c8d354 100644
--- a/tests/providers/check_sqlcipher.c
+++ b/tests/providers/check_sqlcipher.c
@@ -24,6 +24,7 @@
extern GdaProviderInfo *pinfo;
extern GdaConnection *cnc;
+extern gboolean params_provided;
extern gboolean fork_tests;
int
@@ -59,7 +60,11 @@ main (G_GNUC_UNUSED int argc, G_GNUC_UNUSED char **argv)
number_failed += prov_test_common_clean ();
}
- g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
- return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ if (! params_provided)
+ return EXIT_SUCCESS;
+ else {
+ g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
+ return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ }
}
diff --git a/tests/providers/check_sqlite.c b/tests/providers/check_sqlite.c
index 44e071529..7f1ba6906 100644
--- a/tests/providers/check_sqlite.c
+++ b/tests/providers/check_sqlite.c
@@ -23,6 +23,7 @@
extern GdaProviderInfo *pinfo;
extern GdaConnection *cnc;
+extern gboolean params_provided;
extern gboolean fork_tests;
int
@@ -58,7 +59,11 @@ main (G_GNUC_UNUSED int argc, G_GNUC_UNUSED char **argv)
number_failed += prov_test_common_clean ();
}
- g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
- return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ if (! params_provided)
+ return EXIT_SUCCESS;
+ else {
+ g_print ("Test %s\n", (number_failed == 0) ? "Ok" : "failed");
+ return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+ }
}
diff --git a/tests/providers/prov-test-common.c b/tests/providers/prov-test-common.c
index d84c9682a..cc47e4345 100644
--- a/tests/providers/prov-test-common.c
+++ b/tests/providers/prov-test-common.c
@@ -32,6 +32,7 @@
GdaProviderInfo *pinfo;
GdaConnection *cnc;
+gboolean params_provided;
gboolean fork_tests = TRUE;
/*
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]