[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] branch master updated: new file (test case)
From: |
gnunet |
Subject: |
[libeufin] branch master updated: new file (test case) |
Date: |
Wed, 04 May 2022 10:49:45 +0200 |
This is an automated email from the git hooks/post-receive script.
ms pushed a commit to branch master
in repository libeufin.
The following commit(s) were added to refs/heads/master by this push:
new bcc56867 new file (test case)
bcc56867 is described below
commit bcc56867dbecb7f41d52e09753256e1c604b1a8f
Author: ms <ms@taler.net>
AuthorDate: Wed May 4 10:49:41 2022 +0200
new file (test case)
---
util/src/test/kotlin/AmountTest.kt | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/util/src/test/kotlin/AmountTest.kt
b/util/src/test/kotlin/AmountTest.kt
new file mode 100644
index 00000000..bc7ee39b
--- /dev/null
+++ b/util/src/test/kotlin/AmountTest.kt
@@ -0,0 +1,15 @@
+import org.junit.Test
+import tech.libeufin.util.parseAmountAsString
+import kotlin.reflect.typeOf
+
+class AmountTest {
+ @Test
+ fun parse() {
+ val resWithCurrency = parseAmountAsString("CURRENCY:5.5")
+ assert(resWithCurrency.first == "5.5")
+ assert(resWithCurrency.second == "CURRENCY")
+ val resWithoutCurrency = parseAmountAsString("5.5")
+ assert(resWithoutCurrency.first == "5.5")
+ assert(resWithoutCurrency.second == null)
+ }
+}
\ No newline at end of file
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [libeufin] branch master updated: new file (test case),
gnunet <=