mirror of
https://github.com/bblaz/num2words.git
synced 2025-12-06 06:42:25 +00:00
Test currency not implemented, remove dead method.
This commit is contained in:
@@ -195,9 +195,6 @@ class Num2Word_Base(object):
|
|||||||
if not abs(value) == value:
|
if not abs(value) == value:
|
||||||
raise TypeError(self.errmsg_negord % value)
|
raise TypeError(self.errmsg_negord % value)
|
||||||
|
|
||||||
def set_wordnums(self):
|
|
||||||
pass
|
|
||||||
|
|
||||||
def to_ordinal(self, value):
|
def to_ordinal(self, value):
|
||||||
return self.to_cardinal(value)
|
return self.to_cardinal(value)
|
||||||
|
|
||||||
|
|||||||
17
tests/test_base.py
Normal file
17
tests/test_base.py
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
from decimal import Decimal
|
||||||
|
from unittest import TestCase
|
||||||
|
|
||||||
|
from num2words.base import Num2Word_Base
|
||||||
|
|
||||||
|
|
||||||
|
class Num2WordBaseTest(TestCase):
|
||||||
|
@classmethod
|
||||||
|
def setUpClass(cls):
|
||||||
|
super(Num2WordBaseTest, cls).setUpClass()
|
||||||
|
cls.base = Num2Word_Base()
|
||||||
|
|
||||||
|
def test_to_currency_not_implemented(self):
|
||||||
|
with self.assertRaises(NotImplementedError):
|
||||||
|
self.base.to_currency(Decimal('1.00'), currency='EUR')
|
||||||
Reference in New Issue
Block a user