We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7584dc1 commit 6c878efCopy full SHA for 6c878ef
scaleway-core/tests/test_bridge_marshal.py
@@ -0,0 +1,13 @@
1
+import unittest
2
+from decimal import Decimal
3
+
4
+from scaleway_core.bridge import unmarshal_Decimal, marshal_Decimal
5
6
+class TestBridgeMarshal(unittest.TestCase):
7
+ def test_decimal_marshal(self):
8
+ decimal = Decimal('1.2')
9
+ self.assertEqual(marshal_Decimal(decimal), {'value': '1.2'})
10
11
+ def test_decimal_unmarshal(self):
12
13
+ self.assertEqual(unmarshal_Decimal({'value': '1.2'}), decimal)
0 commit comments