Exemple #1
0
 /**
  * Assert that a destroyed flag is set after a card is successfully destroyed.
  *
  */
 public function testDestroy()
 {
     $customer = OmiseCustomer::retrieve('cust_test_4zmrjg2hct06ybwobqc');
     $card = $customer->cards()->retrieve('card_test_4zmrjfzf0spz3mh63cs');
     $card->destroy();
     $this->assertArrayHasKey('object', $card);
     $this->assertEquals('card', $card['object']);
     $this->assertTrue($card->isDestroyed());
 }
Exemple #2
0
 /**
  * Assert that a destroyed flag is set after a customer is successfully destroyed.
  *
  */
 public function testDestroy()
 {
     $customer = OmiseCustomer::retrieve('cust_test_4zmrjg2hct06ybwobqc');
     $customer->destroy();
     $this->assertTrue($customer->isDestroyed());
 }
Exemple #3
0
<?php

$customer = OmiseCustomer::create(array('email' => '*****@*****.**', 'description' => 'John Doe (id: 30)'));
Exemple #4
0
<?php

$customer = OmiseCustomer::retrieve('cust_test_4xtrb759599jsxlhkrb');
Exemple #5
0
<?php

$customer = OmiseCustomer::retrieve('cust_test_4xsjvylia03ur542vn6');
$card = $customer->getCards()->retrieve('card_test_4xsjw0t21xaxnuzi9gs');
# Note that you can reload the card once you have an instance of one.
$card->reload();
Exemple #6
0
<?php

$customer = OmiseCustomer::create(array('email' => '*****@*****.**', 'description' => 'John Doe (id: 30)', 'card' => 'tokn_test_4xs9408a642a1htto8z'));
Exemple #7
0
<?php

$customer = OmiseCustomer::retrieve('cust_test_4ybb9ymhoi7ju6wuizb');
$cards = $customer->getCards();