コード例 #1
0
 def test_set_dicount(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_discount(1.14)
     self.assertIn('extraAmount', transaction.get_dados())
コード例 #2
0
 def test_set_item(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_item(self.item)
     self.assertIn('itemId1', transaction.get_dados())
コード例 #3
0
 def test_set_redirect_url(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_redirect_url('urldeteste.com')
     self.assertIn('redirectURL', transaction.get_dados())
コード例 #4
0
 def test_get_dados_without_item(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.get_dados()
コード例 #5
0
 def test_set_sender_info(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_sender('*****@*****.**', 'Comprador de teste')
     self.assertIn('senderEmail', transaction.get_dados())
     self.assertIn('senderName', transaction.get_dados())
コード例 #6
0
 def test_set_dicount(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_discount(1.14)
     self.assertIn('extraAmount', transaction.get_dados())
コード例 #7
0
 def test_set_redirect_url(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_redirect_url('urldeteste.com')
     self.assertIn('redirectURL', transaction.get_dados())
コード例 #8
0
 def test_set_item(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_item(self.item)
     self.assertIn('itemId1', transaction.get_dados())
コード例 #9
0
 def test_set_sender_info(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.set_sender('*****@*****.**', 'Comprador de teste')
     self.assertIn('senderEmail', transaction.get_dados())
     self.assertIn('senderName', transaction.get_dados())
コード例 #10
0
 def test_get_dados_without_item(self):
     transaction = PagSeguroTransaction('dummy_token', '*****@*****.**')
     transaction.get_dados()