gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] branch master updated: Porting aggregator tests until '


From: gnunet
Subject: [taler-exchange] branch master updated: Porting aggregator tests until 'expect-deposit-6' CMD.
Date: Thu, 16 Jan 2020 19:39:23 +0100

This is an automated email from the git hooks/post-receive script.

marcello pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 9041b899 Porting aggregator tests until 'expect-deposit-6' CMD.
9041b899 is described below

commit 9041b899af4fd262e6b41d0d3abcd678cf6346dd
Author: Marcello Stanisci <address@hidden>
AuthorDate: Thu Jan 16 19:38:38 2020 +0100

    Porting aggregator tests until 'expect-deposit-6' CMD.
---
 src/lib/test_taler_exchange_aggregator.c | 150 ++++++++++++++++++++++++++++++-
 1 file changed, 149 insertions(+), 1 deletion(-)

diff --git a/src/lib/test_taler_exchange_aggregator.c 
b/src/lib/test_taler_exchange_aggregator.c
index bfb3b75e..15fb71a9 100644
--- a/src/lib/test_taler_exchange_aggregator.c
+++ b/src/lib/test_taler_exchange_aggregator.c
@@ -1006,7 +1006,155 @@ run (void *cls,
                                           bc.exchange_payto,
                                           TALER_payto_xtalerbank_make 
(bc.bank_url, "5")),
     TALER_TESTING_cmd_check_bank_empty ("expect-empty-transactions-after-3"),
-    TALER_TESTING_cmd_end ()  
+
+    // checking that aggregator waits for the deadline.
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-4a",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+
+                                     GNUNET_TIME_relative_multiply
+                                       (GNUNET_TIME_UNIT_SECONDS,
+                                        5),
+
+                                     "EUR:0.2",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-4b",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+
+                                     GNUNET_TIME_relative_multiply
+                                       (GNUNET_TIME_UNIT_SECONDS,
+                                        5),
+
+                                     "EUR:0.2",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-4-early",
+                                      config_filename),
+
+    TALER_TESTING_cmd_check_bank_empty 
("expect-empty-transactions-after-4-fast"),
+
+    TALER_TESTING_cmd_sleep ("wait (5s)", 5),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-4-delayed",
+                                      config_filename),
+
+    TALER_TESTING_cmd_check_bank_transfer ("expect-deposit-4",
+                                          ec.exchange_url,
+                                          "EUR:0.19",
+                                          bc.exchange_payto,
+                                          bc.user42_payto),
+
+    // test picking all deposits at earliest deadline
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-5a",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+
+                                     GNUNET_TIME_relative_multiply
+                                       (GNUNET_TIME_UNIT_SECONDS,
+                                        10),
+
+                                     "EUR:0.2",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-5b",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+
+                                     GNUNET_TIME_relative_multiply
+                                       (GNUNET_TIME_UNIT_SECONDS,
+                                        5),
+
+                                     "EUR:0.2",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-5-early",
+                                      config_filename),
+
+    TALER_TESTING_cmd_check_bank_empty 
("expect-empty-transactions-after-5-early"),
+
+    TALER_TESTING_cmd_sleep ("wait (5s)", 5),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-5-delayed",
+                                      config_filename),
+
+    TALER_TESTING_cmd_check_bank_transfer ("expect-deposit-5",
+                                          ec.exchange_url,
+                                          "EUR:0.19",
+                                          bc.exchange_payto,
+                                          bc.user42_payto),
+
+    // Test NEVER running 'tiny' unless they make up minimum unit
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-6a",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+                                     GNUNET_TIME_UNIT_ZERO,
+                                     "EUR:0.102",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-6a-tiny",
+                                      config_filename),
+    TALER_TESTING_cmd_check_bank_empty 
("expect-empty-transactions-after-6a-tiny"),
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-6b",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+                                     GNUNET_TIME_UNIT_ZERO,
+                                     "EUR:0.102",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-6c",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+                                     GNUNET_TIME_UNIT_ZERO,
+                                     "EUR:0.102",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-6c-tiny",
+                                      config_filename),
+    TALER_TESTING_cmd_check_bank_empty 
("expect-empty-transactions-after-6c-tiny"),
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-6d",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+                                     GNUNET_TIME_UNIT_ZERO,
+                                     "EUR:0.102",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-6d-tiny",
+                                      config_filename),
+    TALER_TESTING_cmd_check_bank_empty 
("expect-empty-transactions-after-6d-tiny"),
+
+    TALER_TESTING_cmd_insert_deposit ("do-deposit-6e",
+                                     &dbc,
+                                     "bob",
+                                     USER42_ACCOUNT,
+                                     GNUNET_TIME_UNIT_ZERO,
+                                     "EUR:0.112",
+                                     "EUR:0.1"),
+
+    TALER_TESTING_cmd_exec_aggregator ("run-aggregator-deposit-6e",
+                                      config_filename),
+
+    TALER_TESTING_cmd_check_bank_transfer ("expect-deposit-6",
+                                          ec.exchange_url,
+                                          "EUR:0.01",
+                                          bc.exchange_payto,
+                                          bc.user42_payto),
+
+
+    // Test profiteering if wire deadline is short
+
+    TALER_TESTING_cmd_end () 
   };
   
   TALER_TESTING_run_with_fakebank (is,

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]