This repository has been archived by the owner on Oct 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(Account): Fix account create without company set (#157)
* fix(Account): Fix account create without company set Preventing account from create with company node when it was not set * style(Account): Fix formatting to StyleCI Fix formatting to StyleCI * style(Account): Fix formatting to StyleCI Fix formatting to StyleCI
- Loading branch information
1 parent
f74e51d
commit 4d7f4bc
Showing
2 changed files
with
38 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,6 +13,28 @@ public function testShouldCreateAccount() | |
{ | ||
$this->mockHttpSession($this->body_moip_account); | ||
|
||
$account = $this->moip->accounts() | ||
->setName('Fulano') | ||
->setLastName('De Tal') | ||
->setEmail('[email protected]') | ||
->setIdentityDocument('4737283560', 'SSP', '2015-06-23') | ||
->setBirthDate('1988-12-30') | ||
->setTaxDocument('16262131000') | ||
->setType('MERCHANT') | ||
->setPhone(11, 66778899, 55) | ||
->addAlternativePhone(11, 66448899, 55) | ||
->addAlternativePhone(11, 66338899, 55) | ||
->setTransparentAccount(true) | ||
->addAddress('Rua de teste', 123, 'Bairro', 'Sao Paulo', 'SP', '01234567', 'Apt. 23', 'BRA') | ||
->create(); | ||
|
||
$this->assertNotEmpty($account->getId()); | ||
} | ||
|
||
public function testShouldCreateAccountWithCompany() | ||
{ | ||
$this->mockHttpSession($this->body_moip_account); | ||
|
||
$account = $this->moip->accounts() | ||
->setName('Fulano') | ||
->setLastName('De Tal') | ||
|