예제 #1
0
 def test_one_thousand_and_one(self):
     number = Number(1001)
     self.assertEqual(number.name(), 'one thousand and one')
예제 #2
0
 def test_six_hundred_and_seventy_two(self):
     number = Number(672)
     self.assertEqual(number.name(), 'six hundred and seventy two')
예제 #3
0
 def test_nine_hundred_and_ninety_nine(self):
     number = Number(999)
     self.assertEqual(number.name(), 'nine hundred and ninety nine')
예제 #4
0
 def test_103030060090(self):
     number = Number(103030060090)
     self.assertEqual(number.name(), 'one hundred and three billion, thirty million, sixty thousand and ninety')
예제 #5
0
 def test_negative_six_point_two_eight(self):
     number = Number(-6.28)
     self.assertEqual(number.name(), 'negative six point two eight')
예제 #6
0
 def test_one_million_one_thousand_and_twenty(self):
     number = Number(1001020)
     self.assertEqual(number.name(), 'one million, one thousand and twenty')
예제 #7
0
 def test_1234567890(self):
     number = Number(1234567890)
     self.assertEqual(number.name(), 'one billion, two hundred and thirty four million, five hundred and sixty seven thousand, eight hundred and ninety')
예제 #8
0
 def test_twenty(self):
     number = Number(20)
     self.assertEqual(number.name(), 'twenty')
예제 #9
0
 def test_twenty_one(self):
     number = Number(21)
     self.assertEqual(number.name(), 'twenty one')
예제 #10
0
 def test_thirteen(self):
     number = Number(13)
     self.assertEqual(number.name(), 'thirteen')
예제 #11
0
 def test_sixteen(self):
     number = Number(16)
     self.assertEqual(number.name(), 'sixteen')
예제 #12
0
 def test_ten(self):
     number = Number(10)
     self.assertEqual(number.name(), 'ten')
예제 #13
0
 def test_three(self):
     number = Number(3)
     self.assertEqual(number.name(), 'three')
예제 #14
0
 def test_two(self):
     number = Number(2)
     self.assertEqual(number.name(), 'two')
예제 #15
0
 def test_one_thousand_one_hundred_and_one(self):
     number = Number(1101)
     self.assertEqual(number.name(), 'one thousand, one hundred and one')
예제 #16
0
 def test_ninety_nine(self):
     number = Number(99)
     self.assertEqual(number.name(), 'ninety nine')
예제 #17
0
 def test_one_million_one_thousand(self):
     number = Number(1001000)
     self.assertEqual(number.name(), 'one million, one thousand')
예제 #18
0
 def test_one_hundred(self):
     number = Number(100)
     self.assertEqual(number.name(), 'one hundred')
예제 #19
0
 def test_one_million_and_one(self):
     number = Number(1000001)
     self.assertEqual(number.name(), 'one million and one')
예제 #20
0
 def test_zero(self):
     number = Number(0)
     self.assertEqual(number.name(), 'zero')
예제 #21
0
 def test_one(self):
     number = Number(1)
     self.assertEqual(number.name(), 'one')
예제 #22
0
 def test_one_hundred_and_eleven(self):
     number = Number(111)
     self.assertEqual(number.name(), 'one hundred and eleven')
예제 #23
0
 def test_negative_one(self):
     number = Number(-1)
     self.assertEqual(number.name(), 'negative one')
예제 #24
0
 def test_three_point_one_four(self):
     number = Number(3.14)
     self.assertEqual(number.name(), 'three point one four')