Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions omise/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1994,7 +1994,7 @@ class Source(_MainResource, Base):
>>> source = omise.Source.create(
amount=100000,
currency='thb',
type='internet_banking_scb'
type='promptpay'
)
<Source id='src_test_59ldo3ltuz7418db4ol' at 0x106473668>
>>> charge = omise.Charge.create(
Expand All @@ -2013,7 +2013,7 @@ class Source(_MainResource, Base):
amount=100000,
currency='thb',
source={
'type': 'internet_banking_scb'
'type': 'promptpay'
},
return_uri='https://www.omise.co'
)
Expand Down
6 changes: 3 additions & 3 deletions omise/test/test_charge.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ def test_create_with_source(self, api_call):
"source": {
"object": "source",
"id": "src_test",
"type": "internet_banking_test",
"type": "promptpay",
"flow": "redirect",
"amount": 100000,
"currency": "thb"
Expand Down Expand Up @@ -320,7 +320,7 @@ def test_create_with_source(self, api_call):
amount=100000,
currency='thb',
source={
'type': 'internet_banking_test'
'type': 'promptpay'
},
return_uri='http://www.google.com'
)
Expand All @@ -337,7 +337,7 @@ def test_create_with_source(self, api_call):
'amount': 100000,
'currency': 'thb',
'source': {
'type': 'internet_banking_test'
'type': 'promptpay'
},
'return_uri': 'http://www.google.com'
}
Expand Down
12 changes: 6 additions & 6 deletions omise/test/test_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def _makeOne(self):
return self._getTargetClass().from_data({
'object': 'source',
'id': 'src_test',
'type': 'internet_banking_test',
'type': 'promptpay',
'flow': 'redirect',
'amount': 100000,
'currency': 'thb'
Expand All @@ -26,7 +26,7 @@ def test_create_offsite(self, api_call):
self.mockResponse(api_call, """{
"object": "source",
"id": "src_test",
"type": "internet_banking_test",
"type": "promptpay",
"flow": "redirect",
"amount": 100000,
"currency": "thb"
Expand All @@ -35,7 +35,7 @@ def test_create_offsite(self, api_call):
source = class_.create(
amount=100000,
currency='thb',
type='internet_banking_test'
type='promptpay'
)
self.assertTrue(isinstance(source, class_))
self.assertEqual(source.id, 'src_test')
Expand All @@ -46,7 +46,7 @@ def test_create_offsite(self, api_call):
{
'amount': 100000,
'currency': 'thb',
'type': 'internet_banking_test'
'type': 'promptpay'
}
)

Expand Down Expand Up @@ -86,7 +86,7 @@ def test_retrieve(self, api_call):
self.mockResponse(api_call, """{
"object": "source",
"id": "src_test",
"type": "internet_banking_test",
"type": "promptpay",
"flow": "redirect",
"amount": 100000,
"currency": "thb"
Expand All @@ -95,7 +95,7 @@ def test_retrieve(self, api_call):
source = class_.retrieve('src_test')
self.assertTrue(isinstance(source, class_))
self.assertEqual(source.id, 'src_test')
self.assertEqual(source.type, 'internet_banking_test')
self.assertEqual(source.type, 'promptpay')
self.assertEqual(source.flow, 'redirect')
self.assertEqual(source.amount, 100000)
self.assertEqual(source.currency, 'thb')
Expand Down
Loading