Skip to content

Commit

Permalink
test for repr
Browse files Browse the repository at this point in the history
  • Loading branch information
youknowone committed Apr 25, 2016
1 parent 8a94d0c commit f0afab9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion itunesiap/request.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(self, receipt_data, password=None, proxy_url=None):
self.proxy_url = proxy_url

def __repr__(self):
return u'<Request({}...)>'.format(self.receipt_data[:20])
return u'<Request({0}...)>'.format(self.receipt_data[:20])

@property
def request_content(self):
Expand Down
6 changes: 6 additions & 0 deletions tests/v2_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,5 +255,11 @@ def test_date():
assert d.tzinfo == pytz.timezone('America/Los_Angeles')


def test_repr():
"""Test __repr__"""
request = itunesiap.Request('DummyReceipt')
'{0!r}'.format(request)


if __name__ == '__main__':
pytest.main()

0 comments on commit f0afab9

Please sign in to comment.