gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [taler-wallet-webex] branch master updated: add test for am


From: gnunet
Subject: [GNUnet-SVN] [taler-wallet-webex] branch master updated: add test for amount arithmetic
Date: Thu, 09 Mar 2017 21:35:17 +0100

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

dold pushed a commit to branch master
in repository wallet-webex.

The following commit(s) were added to refs/heads/master by this push:
     new 8b62698  add test for amount arithmetic
8b62698 is described below

commit 8b6269872935c7353a397d45446a4d9ff1b540b6
Author: Florian Dold <address@hidden>
AuthorDate: Thu Mar 9 21:34:55 2017 +0100

    add test for amount arithmetic
---
 src/emscriptif-test.ts | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/src/emscriptif-test.ts b/src/emscriptif-test.ts
index c30a066..3046a14 100644
--- a/src/emscriptif-test.ts
+++ b/src/emscriptif-test.ts
@@ -77,4 +77,13 @@ test("withdraw-request", (t: TestLib) => {
   t.pass();
 });
 
-
+test("withdraw-request", (t: TestLib) => {
+  const a1 = new native.Amount({currency: "KUDOS", value: 1, fraction: 
50000000});
+  const a2 = new native.Amount({currency: "KUDOS", value: 1, fraction: 
50000000});
+  a1.add(a2);
+  let x = a1.toJson();
+  t.assert(x.currency == "KUDOS");
+  t.assert(x.fraction == 0);
+  t.assert(x.value == 3);
+  t.pass();
+});

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



reply via email to

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