diff --git a/tests/Feature/CreditCard/CreditCardTest.php b/tests/Feature/CreditCard/CreditCardTest.php deleted file mode 100644 index 188dc7d9..00000000 --- a/tests/Feature/CreditCard/CreditCardTest.php +++ /dev/null @@ -1,73 +0,0 @@ -actingAs($this->user); - - $response = $this->get('/loans'); - - $response->assertStatus(200); - } - - public function testItShouldNotCreateLoanWithoutSourceAccountId() { - $this->actingAs($this->user); - - $response = $this->post('/loans', array_merge( - $this->loanData, [ - 'source_account_id' => null - ])); - - $response->assertSessionHasErrors(['source_account_id']); - - } - - public function testItShouldNotCreateLoanWithoutFunds() { - $this->actingAs($this->user); - - $response = $this->withoutExceptionHandling()->post('/loans', $this->loanData); - $response->assertSessionHasErrors(); - } - - public function testItShouldCreateLoan() { - $this->actingAs($this->user); - $this->fundAccount('daily_box', $this->loanData['amount'], $this->lender->team_id); - $response = $this->post('/loans', $this->loanData); - $response->assertStatus(302); - $this->assertCount(1, Loan::all()); - } - - public function testLoanShouldHaveStatusPending() { - $this->actingAs($this->user); - $this->fundAccount('daily_box', $this->loanData['amount'], $this->lender->team_id); - - $response = $this->post('/loans', $this->loanData); - $response->assertStatus(302); - $loan = Loan::query()->first(); - - $this->assertEquals($loan->payment_status, Loan::STATUS_PENDING); - } - - public function testClientShouldHaveStatusActive() { - $this->actingAs($this->user); - $this->fundAccount('daily_box', $this->loanData['amount'], $this->lender->team_id); - - $response = $this->post('/loans', $this->loanData); - $response->assertStatus(302); - $loan = Loan::query()->first(); - - $this->assertEquals($loan->client->status, ClientStatus::Active); - } -} diff --git a/tests/Unit/ApapParsingTest.php b/tests/Unit/ApapParsingTest.php new file mode 100644 index 00000000..938fb0cf --- /dev/null +++ b/tests/Unit/ApapParsingTest.php @@ -0,0 +1,23 @@ +assertEquals($product, "Visa GoldAPAP"); + } +} diff --git a/tests/Unit/ExampleTest.php b/tests/Unit/ExampleTest.php index 62e8c3cd..935845e7 100644 --- a/tests/Unit/ExampleTest.php +++ b/tests/Unit/ExampleTest.php @@ -15,4 +15,7 @@ public function test_example() { $this->assertTrue(true); } + + + }