Skip to content

Commit 5a77f41

Browse files
committed
Added tests and unicode to PaymentMethod.
1 parent 6e510c7 commit 5a77f41

2 files changed

Lines changed: 19 additions & 8 deletions

File tree

tests/unit/objects/test_payment.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@
55

66
class PaymentLineTests(unittest.TestCase):
77
def test_unicode(self):
8-
memo_line = PaymentLine()
9-
memo_line.LineNum = 1
10-
memo_line.Description = "Product Description"
11-
memo_line.Amount = 100
8+
payment_line = PaymentLine()
9+
payment_line.LineNum = 1
10+
payment_line.Description = "Product Description"
11+
payment_line.Amount = 100
1212

13-
self.assertEquals(memo_line.__unicode__(), "[1] Product Description 100")
13+
self.assertEquals(payment_line.__unicode__(), "[1] Product Description 100")
1414

1515

1616
class PaymentTests(unittest.TestCase):
1717
def test_unicode(self):
18-
credit_memo = Payment()
19-
credit_memo.TotalAmt = 1000
18+
payment = Payment()
19+
payment.TotalAmt = 1000
2020

21-
self.assertEquals(credit_memo.__unicode__(), 1000)
21+
self.assertEquals(payment.__unicode__(), 1000)
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import unittest
2+
3+
from quickbooks.objects.paymentmethod import PaymentMethod
4+
5+
6+
class PaymentMethodTests(unittest.TestCase):
7+
def test_unicode(self):
8+
payment_method = PaymentMethod()
9+
payment_method.Name = "test"
10+
11+
self.assertEquals(payment_method.__unicode__(), "test")

0 commit comments

Comments
 (0)