aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2019-06-08 21:41:12 +0200
committerChristian Grothoff <christian@grothoff.org>2019-06-08 21:41:12 +0200
commit21edd1e9038cef97c6004dc0b626be43c2138616 (patch)
treef7f9cc7717b36827731ad85f9a4064ad32fa5acb /src
parent36849108451c744c08a358f61217b273918c2e06 (diff)
rename _new.c to just .c for tests
Diffstat (limited to 'src')
-rw-r--r--src/bank-lib/test_bank_api_new.c22
-rw-r--r--src/lib/Makefile.am16
-rw-r--r--src/lib/test_exchange_api.c (renamed from src/lib/test_exchange_api_new.c)4
-rw-r--r--src/lib/test_exchange_api_keys_cherry_picking.c (renamed from src/lib/test_exchange_api_keys_cherry_picking_new.c)4
4 files changed, 18 insertions, 28 deletions
diff --git a/src/bank-lib/test_bank_api_new.c b/src/bank-lib/test_bank_api_new.c
index ab0358c3a..4a89c1931 100644
--- a/src/bank-lib/test_bank_api_new.c
+++ b/src/bank-lib/test_bank_api_new.c
@@ -14,7 +14,7 @@
You should have received a copy of the GNU General Public
License along with TALER; see the file COPYING. If not,
- see <http://www.gnu.org/licenses/>
+ see <http://www.gnu.org/licenses/>
*/
/**
@@ -73,6 +73,7 @@ struct GNUNET_OS_Process *bankd;
*/
char *bank_url;
+
/**
* Main function that will tell the interpreter what commands to
* run.
@@ -83,12 +84,9 @@ static void
run (void *cls,
struct TALER_TESTING_Interpreter *is)
{
-
extern struct TALER_BANK_AuthenticationData AUTHS[];
struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get ();
-
struct TALER_TESTING_Command commands[] = {
-
TALER_TESTING_cmd_bank_history ("history-0",
bank_url,
EXCHANGE_ACCOUNT_NUMBER,
@@ -96,7 +94,6 @@ run (void *cls,
GNUNET_NO,
NULL, /* start */
5),
-
TALER_TESTING_cmd_bank_history_range_with_dates
("history-0-range",
bank_url,
@@ -117,7 +114,6 @@ run (void *cls,
AUTHS[BANK_ACCOUNT_NUMBER -1].details.basic.password,
"subject 1",
"http://exchange.com/"),
-
/* bank gives to exchange */
TALER_TESTING_cmd_fakebank_transfer_with_subject
("deposit-2",
@@ -129,7 +125,6 @@ run (void *cls,
AUTHS[BANK_ACCOUNT_NUMBER -1].details.basic.password,
"subject 2",
"http://exchange.com/"),
-
TALER_TESTING_cmd_bank_history ("history-1c",
bank_url,
EXCHANGE_ACCOUNT_NUMBER,
@@ -137,7 +132,6 @@ run (void *cls,
GNUNET_YES,
NULL,
5),
-
TALER_TESTING_cmd_bank_history ("history-1d",
bank_url,
EXCHANGE_ACCOUNT_NUMBER,
@@ -145,7 +139,6 @@ run (void *cls,
GNUNET_YES,
NULL,
5),
-
TALER_TESTING_cmd_bank_history ("history-1dr",
bank_url,
EXCHANGE_ACCOUNT_NUMBER,
@@ -153,7 +146,6 @@ run (void *cls,
GNUNET_YES,
NULL,
5),
-
TALER_TESTING_cmd_bank_history ("history-2fwd",
bank_url,
EXCHANGE_ACCOUNT_NUMBER,
@@ -161,7 +153,6 @@ run (void *cls,
GNUNET_YES,
"deposit-1",
5),
-
/**
* Just check that the two transactions show up.
*/
@@ -175,7 +166,6 @@ run (void *cls,
50),
ADDSECS (now,
5)),
-
TALER_TESTING_cmd_bank_reject ("reject-1",
bank_url,
"deposit-1"),
@@ -208,16 +198,16 @@ main(int argc,
if (NULL == (bankd =
TALER_TESTING_run_bank (CONFIG_FILE, bank_url)))
return 77;
-
+
ret = TALER_TESTING_setup (&run,
NULL,
CONFIG_FILE,
NULL,
GNUNET_NO); // means no exchange.
- GNUNET_OS_process_kill (bankd, SIGKILL);
- GNUNET_OS_process_wait (bankd);
- GNUNET_OS_process_destroy (bankd);
+ GNUNET_OS_process_kill (bankd, SIGKILL);
+ GNUNET_OS_process_wait (bankd);
+ GNUNET_OS_process_destroy (bankd);
GNUNET_free (bank_url);
if (GNUNET_OK == ret)
diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am
index 33d4f3277..c6a1e241c 100644
--- a/src/lib/Makefile.am
+++ b/src/lib/Makefile.am
@@ -157,9 +157,9 @@ endif
endif
check_PROGRAMS = \
- test_exchange_api_keys_cherry_picking_new \
+ test_exchange_api_keys_cherry_picking \
test_exchange_api_overlapping_keys_bug \
- test_exchange_api_new \
+ test_exchange_api \
test_auditor_api_version \
test_auditor_api
@@ -190,9 +190,9 @@ AM_TESTS_ENVIRONMENT=export TALER_PREFIX=$${TALER_PREFIX:-@libdir@};export PATH=
TESTS = \
$(check_PROGRAMS)
-test_exchange_api_new_SOURCES = \
- test_exchange_api_new.c
-test_exchange_api_new_LDADD = \
+test_exchange_api_SOURCES = \
+ test_exchange_api.c
+test_exchange_api_LDADD = \
libtalertesting.la \
libtalerexchange.la \
$(LIBGCRYPT_LIBS) \
@@ -217,9 +217,9 @@ test_exchange_api_overlapping_keys_bug_LDADD = \
-lgnunetutil \
-ljansson
-test_exchange_api_keys_cherry_picking_new_SOURCES = \
- test_exchange_api_keys_cherry_picking_new.c
-test_exchange_api_keys_cherry_picking_new_LDADD = \
+test_exchange_api_keys_cherry_picking_SOURCES = \
+ test_exchange_api_keys_cherry_picking.c
+test_exchange_api_keys_cherry_picking_LDADD = \
libtalertesting.la \
libtalerexchange.la \
$(LIBGCRYPT_LIBS) \
diff --git a/src/lib/test_exchange_api_new.c b/src/lib/test_exchange_api.c
index bcbdb5ea4..66314b7ce 100644
--- a/src/lib/test_exchange_api_new.c
+++ b/src/lib/test_exchange_api.c
@@ -18,7 +18,7 @@
*/
/**
- * @file exchange/test_exchange_api_new.c
+ * @file exchange/test_exchange_api.c
* @brief testcase to test exchange's HTTP API interface
* @author Sree Harsha Totakura <sreeharsha@totakura.in>
* @author Christian Grothoff
@@ -879,7 +879,7 @@ run (void *cls,
struct TALER_TESTING_Command reserve_open_close
[(RESERVE_OPEN_CLOSE_ITERATIONS
* RESERVE_OPEN_CLOSE_CHUNK) + 1];
-
+
for (unsigned int i = 0;
i < RESERVE_OPEN_CLOSE_ITERATIONS;
i++)
diff --git a/src/lib/test_exchange_api_keys_cherry_picking_new.c b/src/lib/test_exchange_api_keys_cherry_picking.c
index e9763bd4f..91ca65603 100644
--- a/src/lib/test_exchange_api_keys_cherry_picking_new.c
+++ b/src/lib/test_exchange_api_keys_cherry_picking.c
@@ -18,7 +18,7 @@
*/
/**
- * @file exchange-lib/test_exchange_api_keys_cherry_picking_new.c
+ * @file exchange-lib/test_exchange_api_keys_cherry_picking.c
* @brief testcase to test exchange's /keys cherry picking ability
* @author Marcello Stanisci
* @author Christian Grothoff
@@ -215,7 +215,7 @@ run (void *cls,
TALER_TESTING_cmd_check_keys_with_now
("check-keys-3",
- 3,
+ 3,
NDKS_RIGHT_BEFORE_SERIALIZATION,
TTH_parse_time (JAN2030)),