[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-merchant-frontends] branch master updated (534d4c8 -
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-merchant-frontends] branch master updated (534d4c8 -> 3cc56f2) |
Date: |
Fri, 28 Jul 2017 12:38:49 +0200 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a change to branch master
in repository merchant-frontends.
from 534d4c8 testcase run README
new 7b72f5a test donations proposal creation ; URL arguments MUST be
checked.
new 3cc56f2 introducing failing test, as a reminder to implement
arguments checking
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
talerfrontends/donations/donations.py | 1 -
talerfrontends/tests.py | 9 +++++++++
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/talerfrontends/donations/donations.py
b/talerfrontends/donations/donations.py
index 8edf892..2b52c84 100644
--- a/talerfrontends/donations/donations.py
+++ b/talerfrontends/donations/donations.py
@@ -115,7 +115,6 @@ def generate_contract():
jurisdiction="none",
),
)
- print("order: ", order)
r = requests.post(urljoin(BACKEND_URL, 'proposal'), json=dict(order=order))
return flask.jsonify(r.json()), r.status_code
diff --git a/talerfrontends/tests.py b/talerfrontends/tests.py
index 2c4fb18..3d28995 100755
--- a/talerfrontends/tests.py
+++ b/talerfrontends/tests.py
@@ -21,6 +21,15 @@ class DonationsTestCase(unittest.TestCase):
response = self.app.get("/")
assert 200 == response.status_code
+ def test_proposal_creation(self):
+ qs = "/generate-contract?donation_receiver=Tor&donation_amount=1.0"
+ bad_qs = "/generate-contract?buggy=qs"
+ response = self.app.get(qs)
+ assert 200 == response.status_code
+ response = self.app.get(bad_qs)
+ # FIXME: might NOT be 400 here
+ assert 400 == response.status_code
+
class BlogTestCase(unittest.TestCase):
def setUp(self):
bapp.testing = True
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [taler-merchant-frontends] branch master updated (534d4c8 -> 3cc56f2),
gnunet <=