From c44e8330a503b6c98239315f59a2ac1c0459e4e1 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Thu, 15 Oct 2020 13:07:48 +1100 Subject: [PATCH] Fixes for tests --- .../migrations/2020_10_14_201320_project_ids_to_entities.php | 2 +- tests/Unit/AutoBillInvoiceTest.php | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/database/migrations/2020_10_14_201320_project_ids_to_entities.php b/database/migrations/2020_10_14_201320_project_ids_to_entities.php index 9d3af7e58eb5..5b61a0a911fe 100644 --- a/database/migrations/2020_10_14_201320_project_ids_to_entities.php +++ b/database/migrations/2020_10_14_201320_project_ids_to_entities.php @@ -21,7 +21,7 @@ class ProjectIdsToEntities extends Migration $table->longText('fields')->change(); }); - Schema::table('gateways', function (Blueprint $table) { + Schema::table('companies', function (Blueprint $table) { $table->boolean('mark_expenses_invoiceable')->default(0); $table->boolean('mark_expenses_paid')->default(0); $table->enum('use_credits_payment', ['always', 'off', 'optin'])->nullable(); diff --git a/tests/Unit/AutoBillInvoiceTest.php b/tests/Unit/AutoBillInvoiceTest.php index 5b7e4c89e05c..26b276b25a09 100644 --- a/tests/Unit/AutoBillInvoiceTest.php +++ b/tests/Unit/AutoBillInvoiceTest.php @@ -33,7 +33,9 @@ class AutoBillInvoiceTest extends TestCase public function testAutoBillFunctionality() { - + $this->company->use_credits_payment = 'always'; + $this->company->save(); + $this->assertEquals($this->client->balance, 10); $this->assertEquals($this->client->paid_to_date, 0); $this->assertEquals($this->client->credit_balance, 10);