Reviewed all tests for Travis
This commit is contained in:
parent
e6560f88a6
commit
9e0cdec575
@ -73,7 +73,7 @@ class AccountsTest extends FeatureTestCase
|
|||||||
|
|
||||||
private function getAccountRequest()
|
private function getAccountRequest()
|
||||||
{
|
{
|
||||||
return[
|
return [
|
||||||
'company_id' => $this->company->id,
|
'company_id' => $this->company->id,
|
||||||
'name' => $this->faker->text(5),
|
'name' => $this->faker->text(5),
|
||||||
'number' => '1',
|
'number' => '1',
|
||||||
@ -87,4 +87,3 @@ class AccountsTest extends FeatureTestCase
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
namespace Tests\Feature\Banking;
|
namespace Tests\Feature\Banking;
|
||||||
|
|
||||||
use App\Models\Banking\Reconciliation;
|
use App\Models\Banking\Reconciliation;
|
||||||
use Tests\Feature\FeatureTestCase;
|
use Tests\Feature\FeatureTestCase;
|
||||||
|
|
||||||
|
@ -120,7 +120,7 @@ class TransfersTest extends FeatureTestCase
|
|||||||
'payment_method' => 'offlinepayment.cash.1',
|
'payment_method' => 'offlinepayment.cash.1',
|
||||||
'reference' => null,
|
'reference' => null,
|
||||||
'currency_code' => setting('general.default_currency'),
|
'currency_code' => setting('general.default_currency'),
|
||||||
'currency_rate' => '1',
|
'currency_rate' => '1'
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -140,7 +140,7 @@ class TransfersTest extends FeatureTestCase
|
|||||||
'category_id' => $this->company->categories()->type('income')->first()->id,
|
'category_id' => $this->company->categories()->type('income')->first()->id,
|
||||||
'reference' => $this->faker->text(5),
|
'reference' => $this->faker->text(5),
|
||||||
'payment_method' => setting('general.default_payment_method'),
|
'payment_method' => setting('general.default_payment_method'),
|
||||||
'attachment' => $attachment,
|
'attachment' => $attachment
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -160,7 +160,7 @@ class TransfersTest extends FeatureTestCase
|
|||||||
'category_id' => $this->company->categories()->type('expense')->first()->id,
|
'category_id' => $this->company->categories()->type('expense')->first()->id,
|
||||||
'payment_method' => setting('general.default_payment_method'),
|
'payment_method' => setting('general.default_payment_method'),
|
||||||
'reference' => $this->faker->text(5),
|
'reference' => $this->faker->text(5),
|
||||||
'attachment' => $attachment,
|
'attachment' => $attachment
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -50,7 +50,6 @@ class BillReminderTest extends FeatureTestCase
|
|||||||
|
|
||||||
$items = [['name' => $this->faker->text(5), 'item_id' => null, 'quantity' => '1', 'price' => $amount, 'currency' => 'USD']];
|
$items = [['name' => $this->faker->text(5), 'item_id' => null, 'quantity' => '1', 'price' => $amount, 'currency' => 'USD']];
|
||||||
|
|
||||||
|
|
||||||
$data = [
|
$data = [
|
||||||
'vendor_id' => '0',
|
'vendor_id' => '0',
|
||||||
'billed_at' => $this->faker->date(),
|
'billed_at' => $this->faker->date(),
|
||||||
@ -74,7 +73,6 @@ class BillReminderTest extends FeatureTestCase
|
|||||||
'company_id' => $this->company->id,
|
'company_id' => $this->company->id,
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
return $data;
|
return $data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -50,7 +50,6 @@ class InvoiceReminderTest extends FeatureTestCase
|
|||||||
|
|
||||||
$items = [['name' => $this->faker->text(5), 'item_id' => null, 'quantity' => '1', 'price' => $amount, 'currency' => 'USD']];
|
$items = [['name' => $this->faker->text(5), 'item_id' => null, 'quantity' => '1', 'price' => $amount, 'currency' => 'USD']];
|
||||||
|
|
||||||
|
|
||||||
$data = [
|
$data = [
|
||||||
'customer_id' => '0',
|
'customer_id' => '0',
|
||||||
'invoiced_at' => $this->faker->date(),
|
'invoiced_at' => $this->faker->date(),
|
||||||
|
@ -8,7 +8,6 @@ use Tests\Feature\FeatureTestCase;
|
|||||||
|
|
||||||
class PaymentsTest extends FeatureTestCase
|
class PaymentsTest extends FeatureTestCase
|
||||||
{
|
{
|
||||||
|
|
||||||
public function testItShouldSeePaymentListPage()
|
public function testItShouldSeePaymentListPage()
|
||||||
{
|
{
|
||||||
$this->loginAs()
|
$this->loginAs()
|
||||||
@ -82,5 +81,4 @@ class PaymentsTest extends FeatureTestCase
|
|||||||
'attachment' => $attachment,
|
'attachment' => $attachment,
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -80,7 +80,6 @@ class VendorsTest extends FeatureTestCase
|
|||||||
->assertRedirect(route('vendors.index'));
|
->assertRedirect(route('vendors.index'));
|
||||||
|
|
||||||
$this->assertFlashLevel('success');
|
$this->assertFlashLevel('success');
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getVendorRequest()
|
private function getVendorRequest()
|
||||||
@ -97,5 +96,4 @@ class VendorsTest extends FeatureTestCase
|
|||||||
'enabled' => $this->faker->boolean ? 1 : 0
|
'enabled' => $this->faker->boolean ? 1 : 0
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -27,6 +27,11 @@ abstract class FeatureTestCase extends TestCase
|
|||||||
$this->faker = Factory::create();
|
$this->faker = Factory::create();
|
||||||
$this->user = User::first();
|
$this->user = User::first();
|
||||||
$this->company = $this->user->first()->companies()->first();
|
$this->company = $this->user->first()->companies()->first();
|
||||||
|
|
||||||
|
// Set Company settings
|
||||||
|
setting()->forgetAll();
|
||||||
|
setting()->setExtraColumns(['company_id' => $this->company->id]);
|
||||||
|
setting()->load(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -58,7 +58,6 @@ class InvoicesTest extends FeatureTestCase
|
|||||||
->assertStatus(302);
|
->assertStatus(302);
|
||||||
|
|
||||||
$this->assertFlashLevel('success');
|
$this->assertFlashLevel('success');
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItShouldDeleteInvoice()
|
public function testItShouldDeleteInvoice()
|
||||||
@ -71,7 +70,6 @@ class InvoicesTest extends FeatureTestCase
|
|||||||
->assertRedirect(url('incomes/invoices'));
|
->assertRedirect(url('incomes/invoices'));
|
||||||
|
|
||||||
$this->assertFlashLevel('success');
|
$this->assertFlashLevel('success');
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getInvoiceRequest($recurring = 0)
|
private function getInvoiceRequest($recurring = 0)
|
||||||
|
@ -7,7 +7,6 @@ use Tests\Feature\FeatureTestCase;
|
|||||||
|
|
||||||
class CurrenciesTest extends FeatureTestCase
|
class CurrenciesTest extends FeatureTestCase
|
||||||
{
|
{
|
||||||
|
|
||||||
public function testItShouldSeeCurrencyListPage()
|
public function testItShouldSeeCurrencyListPage()
|
||||||
{
|
{
|
||||||
$this->loginAs()
|
$this->loginAs()
|
||||||
@ -62,7 +61,6 @@ class CurrenciesTest extends FeatureTestCase
|
|||||||
$this->assertFlashLevel('success');
|
$this->assertFlashLevel('success');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private function getCurrencyRequest()
|
private function getCurrencyRequest()
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user