diff --git a/tests/Feature/AgencyProfileTest.php b/tests/Feature/AgencyProfileTest.php index e10b8c3..56c9854 100644 --- a/tests/Feature/AgencyProfileTest.php +++ b/tests/Feature/AgencyProfileTest.php @@ -3,6 +3,7 @@ namespace Tests\Feature\Users; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Agency Profile Feature Test. @@ -11,6 +12,8 @@ use Tests\TestCase; */ class AgencyProfileTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_user_can_visit_agency_page() { diff --git a/tests/Feature/Api/ApiEventsTest.php b/tests/Feature/Api/ApiEventsTest.php index 52647e9..2c20f10 100644 --- a/tests/Feature/Api/ApiEventsTest.php +++ b/tests/Feature/Api/ApiEventsTest.php @@ -6,6 +6,7 @@ use Tests\TestCase; use App\Entities\Users\User; use App\Entities\Users\Event; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Events API Feature Test. @@ -14,6 +15,8 @@ use App\Entities\Projects\Project; */ class ApiEventsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function it_can_get_all_existing_events() { diff --git a/tests/Feature/Api/ApiManageProjectsTest.php b/tests/Feature/Api/ApiManageProjectsTest.php index 168878b..baac1a2 100644 --- a/tests/Feature/Api/ApiManageProjectsTest.php +++ b/tests/Feature/Api/ApiManageProjectsTest.php @@ -4,6 +4,7 @@ namespace Tests\Feature\Api; use Tests\TestCase; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Projects API Feature Test. @@ -12,6 +13,8 @@ use App\Entities\Projects\Project; */ class ApiManageProjectsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_get_project_lists() { diff --git a/tests/Feature/Api/Projects/ReorderJobListTest.php b/tests/Feature/Api/Projects/ReorderJobListTest.php index 64127b6..0645922 100644 --- a/tests/Feature/Api/Projects/ReorderJobListTest.php +++ b/tests/Feature/Api/Projects/ReorderJobListTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature\Api\Projects; use Tests\TestCase; use App\Entities\Projects\Job; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ReorderJobListTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_reorder_job_position() { diff --git a/tests/Feature/Api/Projects/ReorderTaskListTest.php b/tests/Feature/Api/Projects/ReorderTaskListTest.php index c964006..70a2cef 100644 --- a/tests/Feature/Api/Projects/ReorderTaskListTest.php +++ b/tests/Feature/Api/Projects/ReorderTaskListTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature\Api\Projects; use Tests\TestCase; use App\Entities\Projects\Task; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ReorderTaskListTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_reorder_task_position() { diff --git a/tests/Feature/Auth/ChangePasswordTest.php b/tests/Feature/Auth/ChangePasswordTest.php index ac24571..b57416f 100644 --- a/tests/Feature/Auth/ChangePasswordTest.php +++ b/tests/Feature/Auth/ChangePasswordTest.php @@ -3,9 +3,12 @@ namespace Tests\Feature\Auth; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ChangePasswordTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function member_can_change_password() { diff --git a/tests/Feature/Auth/LoginTest.php b/tests/Feature/Auth/LoginTest.php index 1fd4ccd..531ea53 100644 --- a/tests/Feature/Auth/LoginTest.php +++ b/tests/Feature/Auth/LoginTest.php @@ -4,9 +4,12 @@ namespace Tests\Feature\Auth; use Tests\TestCase; use App\Entities\Users\User; +use Illuminate\Foundation\Testing\DatabaseMigrations; class LoginTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_login_and_logout() { diff --git a/tests/Feature/Auth/ResetPasswordTest.php b/tests/Feature/Auth/ResetPasswordTest.php index 2c8d212..9d43bca 100644 --- a/tests/Feature/Auth/ResetPasswordTest.php +++ b/tests/Feature/Auth/ResetPasswordTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature\Auth; use Notification; use Tests\TestCase; use App\Entities\Users\User; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ResetPasswordTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_reset_password_by_their_email() { diff --git a/tests/Feature/InstallationTest.php b/tests/Feature/InstallationTest.php index 7917e7c..496ea21 100644 --- a/tests/Feature/InstallationTest.php +++ b/tests/Feature/InstallationTest.php @@ -4,6 +4,7 @@ namespace Tests\Feature; use Tests\TestCase; use App\Entities\Users\User; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Installation Feature Test. @@ -12,6 +13,8 @@ use App\Entities\Users\User; */ class InstallationTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_cannot_visit_install_page_if_user_already_exists_in_database() { diff --git a/tests/Feature/Invoices/InvoiceDuplicateTest.php b/tests/Feature/Invoices/InvoiceDuplicateTest.php index b518e82..509ac12 100644 --- a/tests/Feature/Invoices/InvoiceDuplicateTest.php +++ b/tests/Feature/Invoices/InvoiceDuplicateTest.php @@ -4,6 +4,7 @@ namespace Tests\Feature\Invoices; use Tests\TestCase; use App\Entities\Invoices\Invoice; +use Illuminate\Foundation\Testing\DatabaseMigrations; use App\Services\InvoiceDrafts\InvoiceDraftCollection; /** @@ -13,6 +14,8 @@ use App\Services\InvoiceDrafts\InvoiceDraftCollection; */ class InvoiceDuplicateTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_create_invoice_draft_by_duplicate_existing_invoice() { diff --git a/tests/Feature/Invoices/InvoiceEntryTest.php b/tests/Feature/Invoices/InvoiceEntryTest.php index 389ef29..b635e7b 100644 --- a/tests/Feature/Invoices/InvoiceEntryTest.php +++ b/tests/Feature/Invoices/InvoiceEntryTest.php @@ -7,6 +7,7 @@ use App\Entities\Projects\Project; use App\Entities\Partners\Customer; use App\Services\InvoiceDrafts\Item; use App\Services\InvoiceDrafts\InvoiceDraft; +use Illuminate\Foundation\Testing\DatabaseMigrations; use App\Services\InvoiceDrafts\InvoiceDraftCollection; /** @@ -16,6 +17,8 @@ use App\Services\InvoiceDrafts\InvoiceDraftCollection; */ class InvoiceEntryTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_visit_invoice_drafts_page() { diff --git a/tests/Feature/Invoices/ManageInvoicesTest.php b/tests/Feature/Invoices/ManageInvoicesTest.php index e3e6a6f..ff74ab1 100644 --- a/tests/Feature/Invoices/ManageInvoicesTest.php +++ b/tests/Feature/Invoices/ManageInvoicesTest.php @@ -4,6 +4,7 @@ namespace Tests\Feature\Invoices; use Tests\TestCase; use App\Entities\Invoices\Invoice; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Invoices Feature Test. @@ -12,6 +13,8 @@ use App\Entities\Invoices\Invoice; */ class ManageInvoicesTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_browse_invoice_list_page() { diff --git a/tests/Feature/ManageJobsTest.php b/tests/Feature/ManageJobsTest.php index e3beefb..c9972d9 100644 --- a/tests/Feature/ManageJobsTest.php +++ b/tests/Feature/ManageJobsTest.php @@ -8,6 +8,7 @@ use App\Entities\Projects\Job; use App\Entities\Projects\Task; use App\Entities\Projects\Project; use App\Entities\Partners\Customer; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Project Feature Test. @@ -16,6 +17,8 @@ use App\Entities\Partners\Customer; */ class ManageJobsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_entry_job() { diff --git a/tests/Feature/ManageProjectsTest.php b/tests/Feature/ManageProjectsTest.php index 52b78ed..379d9f5 100644 --- a/tests/Feature/ManageProjectsTest.php +++ b/tests/Feature/ManageProjectsTest.php @@ -8,9 +8,12 @@ use App\Entities\Projects\Task; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; use App\Entities\Partners\Customer; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ManageProjectsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_input_new_project_with_existing_customer() { diff --git a/tests/Feature/ManageSubscriptionsTest.php b/tests/Feature/ManageSubscriptionsTest.php index b8e6ada..96e4683 100644 --- a/tests/Feature/ManageSubscriptionsTest.php +++ b/tests/Feature/ManageSubscriptionsTest.php @@ -6,9 +6,12 @@ use Tests\TestCase; use App\Entities\Partners\Vendor; use App\Entities\Projects\Project; use App\Entities\Subscriptions\Subscription; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ManageSubscriptionsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_entry_subscription() { diff --git a/tests/Feature/ManageTasksTest.php b/tests/Feature/ManageTasksTest.php index 0ed67d2..8831084 100644 --- a/tests/Feature/ManageTasksTest.php +++ b/tests/Feature/ManageTasksTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature; use Tests\TestCase; use App\Entities\Projects\Job; use App\Entities\Projects\Task; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ManageTasksTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_entry_task() { diff --git a/tests/Feature/Partners/ManageCustomersTest.php b/tests/Feature/Partners/ManageCustomersTest.php index 9660eda..8013d34 100644 --- a/tests/Feature/Partners/ManageCustomersTest.php +++ b/tests/Feature/Partners/ManageCustomersTest.php @@ -2,7 +2,7 @@ namespace Tests\Feature; -use Tests\TestCase as TestCase; +use Tests\TestCase; use App\Entities\Partners\Customer; use Illuminate\Foundation\Testing\DatabaseMigrations; diff --git a/tests/Feature/Partners/ManageVendorsTest.php b/tests/Feature/Partners/ManageVendorsTest.php index a258629..c3dacce 100644 --- a/tests/Feature/Partners/ManageVendorsTest.php +++ b/tests/Feature/Partners/ManageVendorsTest.php @@ -2,11 +2,14 @@ namespace Tests\Feature\Partners; -use Tests\TestCase as TestCase; +use Tests\TestCase; use App\Entities\Partners\Vendor; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ManageVendorsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_see_vendor_list_in_vendor_index_page() { diff --git a/tests/Feature/Payments/ManagePaymentsTest.php b/tests/Feature/Payments/ManagePaymentsTest.php index 7ac0f3d..9d0133b 100644 --- a/tests/Feature/Payments/ManagePaymentsTest.php +++ b/tests/Feature/Payments/ManagePaymentsTest.php @@ -7,6 +7,7 @@ use App\Entities\Partners\Vendor; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; use App\Entities\Partners\Customer; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Payments Feature Test. @@ -15,6 +16,8 @@ use App\Entities\Partners\Customer; */ class ManagePaymentsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_entry_project_an_income_payment() { diff --git a/tests/Feature/Payments/ManageProjectFeesTest.php b/tests/Feature/Payments/ManageProjectFeesTest.php index fb2c226..0a859b3 100644 --- a/tests/Feature/Payments/ManageProjectFeesTest.php +++ b/tests/Feature/Payments/ManageProjectFeesTest.php @@ -6,9 +6,12 @@ use Tests\TestCase; use App\Entities\Users\User; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ManageProjectFeesTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_entry_project_fee_payment() { diff --git a/tests/Feature/Payments/PaymentSearchTest.php b/tests/Feature/Payments/PaymentSearchTest.php index 1483e7d..d273226 100644 --- a/tests/Feature/Payments/PaymentSearchTest.php +++ b/tests/Feature/Payments/PaymentSearchTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature\Payments; use Tests\TestCase; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class PaymentSearchTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_find_payment_by_project_name() { diff --git a/tests/Feature/Projects/JobCommentsTest.php b/tests/Feature/Projects/JobCommentsTest.php index 4263a42..186ff85 100644 --- a/tests/Feature/Projects/JobCommentsTest.php +++ b/tests/Feature/Projects/JobCommentsTest.php @@ -5,9 +5,12 @@ namespace Tests\Feature\Projects; use Tests\TestCase; use App\Entities\Projects\Job; use App\Entities\Projects\Comment; +use Illuminate\Foundation\Testing\DatabaseMigrations; class JobCommentsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_view_job_comments() { diff --git a/tests/Feature/Projects/UploadFilesTest.php b/tests/Feature/Projects/UploadFilesTest.php index 232e9f0..60556cf 100644 --- a/tests/Feature/Projects/UploadFilesTest.php +++ b/tests/Feature/Projects/UploadFilesTest.php @@ -6,9 +6,12 @@ use Storage; use Tests\TestCase; use Illuminate\Http\UploadedFile; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class UploadFilesTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_upload_document_to_a_project() { diff --git a/tests/Feature/References/SiteOptionsTest.php b/tests/Feature/References/SiteOptionsTest.php index 948bb13..8c34e14 100644 --- a/tests/Feature/References/SiteOptionsTest.php +++ b/tests/Feature/References/SiteOptionsTest.php @@ -3,6 +3,7 @@ namespace Tests\Feature\Users; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Site Options Feature Test. @@ -11,6 +12,8 @@ use Tests\TestCase; */ class SiteOptionsTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_user_can_visit_site_options_page() { diff --git a/tests/Feature/Users/ManageUsersTest.php b/tests/Feature/Users/ManageUsersTest.php index 56f2254..57d3d39 100644 --- a/tests/Feature/Users/ManageUsersTest.php +++ b/tests/Feature/Users/ManageUsersTest.php @@ -4,6 +4,7 @@ namespace Tests\Feature\Users; use Tests\TestCase; use App\Entities\Users\User; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Manage Users Feature Test. @@ -12,6 +13,8 @@ use App\Entities\Users\User; */ class ManageUsersTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_can_see_user_list_from_dashboard_tab() { diff --git a/tests/Feature/Users/UserProfileTest.php b/tests/Feature/Users/UserProfileTest.php index 6223d9f..fef6f3c 100644 --- a/tests/Feature/Users/UserProfileTest.php +++ b/tests/Feature/Users/UserProfileTest.php @@ -3,6 +3,7 @@ namespace Tests\Feature\Users; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * User Profile Feature Test. @@ -11,6 +12,8 @@ use Tests\TestCase; */ class UserProfileTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function a_user_can_visit_their_profile_page() { diff --git a/tests/TestCase.php b/tests/TestCase.php index 18a7d76..8ad9de8 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -3,12 +3,11 @@ namespace Tests; use App\Entities\Users\User; -use Illuminate\Foundation\Testing\DatabaseMigrations; use Laravel\BrowserKitTesting\TestCase as BaseTestCase; abstract class TestCase extends BaseTestCase { - use CreatesApplication, DatabaseMigrations; + use CreatesApplication; protected function adminUserSigningIn($userDataOverrides = []) { diff --git a/tests/Unit/Helpers/AppLogoImageTest.php b/tests/Unit/Helpers/AppLogoImageTest.php index a0538c0..14d508e 100644 --- a/tests/Unit/Helpers/AppLogoImageTest.php +++ b/tests/Unit/Helpers/AppLogoImageTest.php @@ -3,9 +3,12 @@ namespace Tests\Unit\Helpers; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; class AppLogoImageTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function app_logo_path_function_returns_correct_logo_image_path_based_on_agency_logo_path_setting() { diff --git a/tests/Unit/Helpers/MoneyFormatTest.php b/tests/Unit/Helpers/MoneyFormatTest.php index a536b9c..fc0384c 100644 --- a/tests/Unit/Helpers/MoneyFormatTest.php +++ b/tests/Unit/Helpers/MoneyFormatTest.php @@ -3,6 +3,7 @@ namespace Tests\Unit\Helpers; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Money Format Helper Unit Test. @@ -11,6 +12,8 @@ use Tests\TestCase; */ class MoneyFormatTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function format_money_returns_string_with_default_money_sign() { diff --git a/tests/Unit/Models/CustomerTest.php b/tests/Unit/Models/CustomerTest.php index a588450..3784653 100644 --- a/tests/Unit/Models/CustomerTest.php +++ b/tests/Unit/Models/CustomerTest.php @@ -2,16 +2,19 @@ namespace Tests\Unit\Models; -use Tests\TestCase as TestCase; +use Tests\TestCase; use App\Entities\Invoices\Invoice; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; use Illuminate\Support\Collection; use App\Entities\Partners\Customer; use App\Entities\Subscriptions\Subscription; +use Illuminate\Foundation\Testing\DatabaseMigrations; class CustomerTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function a_customer_has_many_projects() { diff --git a/tests/Unit/Models/InvoiceTest.php b/tests/Unit/Models/InvoiceTest.php index 64d1b46..8a456f3 100644 --- a/tests/Unit/Models/InvoiceTest.php +++ b/tests/Unit/Models/InvoiceTest.php @@ -6,6 +6,7 @@ use Tests\TestCase; use App\Entities\Users\User; use App\Entities\Invoices\Invoice; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Invoice Model Test. @@ -14,6 +15,8 @@ use App\Entities\Projects\Project; */ class InvoiceTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function it_has_project_relation() { diff --git a/tests/Unit/Models/JobTest.php b/tests/Unit/Models/JobTest.php index 2bd3d53..c92fc37 100644 --- a/tests/Unit/Models/JobTest.php +++ b/tests/Unit/Models/JobTest.php @@ -8,6 +8,7 @@ use App\Entities\Projects\Task; use App\Entities\Projects\Comment; use App\Entities\Projects\Project; use Illuminate\Support\Collection; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Job Model Unit Test. @@ -16,6 +17,8 @@ use Illuminate\Support\Collection; */ class JobTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function a_job_has_name_link_method() { diff --git a/tests/Unit/Models/PaymentTest.php b/tests/Unit/Models/PaymentTest.php index e110e7c..f1df1ee 100644 --- a/tests/Unit/Models/PaymentTest.php +++ b/tests/Unit/Models/PaymentTest.php @@ -7,9 +7,12 @@ use App\Entities\Users\User; use App\Entities\Partners\Vendor; use App\Entities\Payments\Payment; use App\Entities\Partners\Customer; +use Illuminate\Foundation\Testing\DatabaseMigrations; class PaymentTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function it_can_have_partner_relation_on_customer_model_for_income_payment() { diff --git a/tests/Unit/Models/ProjectTest.php b/tests/Unit/Models/ProjectTest.php index 6fb19d3..24c5264 100644 --- a/tests/Unit/Models/ProjectTest.php +++ b/tests/Unit/Models/ProjectTest.php @@ -11,9 +11,12 @@ use App\Entities\Projects\Project; use Illuminate\Support\Collection; use App\Entities\Partners\Customer; use App\Entities\Subscriptions\Subscription; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ProjectTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function a_project_has_name_link_method() { diff --git a/tests/Unit/Models/SubscriptionTest.php b/tests/Unit/Models/SubscriptionTest.php index 5ca41d2..af0f041 100644 --- a/tests/Unit/Models/SubscriptionTest.php +++ b/tests/Unit/Models/SubscriptionTest.php @@ -9,9 +9,12 @@ use App\Entities\Projects\Project; use App\Entities\Partners\Customer; use App\Entities\Subscriptions\Type; use App\Entities\Subscriptions\Subscription; +use Illuminate\Foundation\Testing\DatabaseMigrations; class SubscriptionTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function it_has_name_link_method() { diff --git a/tests/Unit/Models/UserTest.php b/tests/Unit/Models/UserTest.php index a42939a..caaafad 100644 --- a/tests/Unit/Models/UserTest.php +++ b/tests/Unit/Models/UserTest.php @@ -8,6 +8,7 @@ use App\Entities\Projects\Job; use App\Entities\Payments\Payment; use App\Entities\Projects\Project; use Illuminate\Support\Collection; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * User Model Unit Test. @@ -16,6 +17,8 @@ use Illuminate\Support\Collection; */ class UserTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function user_has_name_link_method() { diff --git a/tests/Unit/Models/VendorTest.php b/tests/Unit/Models/VendorTest.php index 9e9437d..59ed5a9 100644 --- a/tests/Unit/Models/VendorTest.php +++ b/tests/Unit/Models/VendorTest.php @@ -2,7 +2,7 @@ namespace Tests\Unit\Models; -use Tests\TestCase as TestCase; +use Tests\TestCase; use App\Entities\Partners\Vendor; use App\Entities\Payments\Payment; use Illuminate\Support\Collection; diff --git a/tests/Unit/Policies/CommentPolicyTest.php b/tests/Unit/Policies/CommentPolicyTest.php index b06b879..51cf568 100644 --- a/tests/Unit/Policies/CommentPolicyTest.php +++ b/tests/Unit/Policies/CommentPolicyTest.php @@ -4,9 +4,12 @@ namespace Tests\Unit\Policies; use Tests\TestCase; use App\Entities\Projects\Comment; +use Illuminate\Foundation\Testing\DatabaseMigrations; class CommentPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function admin_can_edit_any_comments() { diff --git a/tests/Unit/Policies/CustomerPolicyTest.php b/tests/Unit/Policies/CustomerPolicyTest.php index 468db10..af9093f 100644 --- a/tests/Unit/Policies/CustomerPolicyTest.php +++ b/tests/Unit/Policies/CustomerPolicyTest.php @@ -4,6 +4,7 @@ namespace Tests\Unit\Policies; use Tests\TestCase; use App\Entities\Partners\Customer; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Customer Policy Test. @@ -12,6 +13,8 @@ use App\Entities\Partners\Customer; */ class CustomerPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function only_admin_can_create_customer() { diff --git a/tests/Unit/Policies/JobPolicyTest.php b/tests/Unit/Policies/JobPolicyTest.php index 056b177..ac17b13 100644 --- a/tests/Unit/Policies/JobPolicyTest.php +++ b/tests/Unit/Policies/JobPolicyTest.php @@ -4,9 +4,12 @@ namespace Tests\Unit\Policies; use Tests\TestCase; use App\Entities\Projects\Job; +use Illuminate\Foundation\Testing\DatabaseMigrations; class JobPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function an_admin_can_create_job_on_a_project() { diff --git a/tests/Unit/Policies/PaymentPolicyTest.php b/tests/Unit/Policies/PaymentPolicyTest.php index 36e5cdd..dea049e 100644 --- a/tests/Unit/Policies/PaymentPolicyTest.php +++ b/tests/Unit/Policies/PaymentPolicyTest.php @@ -2,8 +2,9 @@ namespace Tests\Unit\Policies; -use Tests\TestCase as TestCase; +use Tests\TestCase; use App\Entities\Payments\Payment; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Payment Policy Test. @@ -12,6 +13,8 @@ use App\Entities\Payments\Payment; */ class PaymentPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function only_admin_can_create_payment() { diff --git a/tests/Unit/Policies/ProjectPolicyTest.php b/tests/Unit/Policies/ProjectPolicyTest.php index 6d711af..ac24478 100644 --- a/tests/Unit/Policies/ProjectPolicyTest.php +++ b/tests/Unit/Policies/ProjectPolicyTest.php @@ -2,12 +2,15 @@ namespace Tests\Unit\Policies; +use Tests\TestCase; use App\Entities\Projects\Job; -use Tests\TestCase as TestCase; use App\Entities\Projects\Project; +use Illuminate\Foundation\Testing\DatabaseMigrations; class ProjectPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function only_admin_can_create_project() { diff --git a/tests/Unit/Policies/TaskPolicyTest.php b/tests/Unit/Policies/TaskPolicyTest.php index 843c316..f4ff8b3 100644 --- a/tests/Unit/Policies/TaskPolicyTest.php +++ b/tests/Unit/Policies/TaskPolicyTest.php @@ -2,12 +2,15 @@ namespace Tests\Unit\Policies; +use Tests\TestCase; use App\Entities\Projects\Job; use App\Entities\Projects\Task; -use Tests\TestCase as TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; class TaskPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function only_admin_can_create_task_on_a_job() { diff --git a/tests/Unit/Policies/UserPolicyTest.php b/tests/Unit/Policies/UserPolicyTest.php index 056efda..d9aa5aa 100644 --- a/tests/Unit/Policies/UserPolicyTest.php +++ b/tests/Unit/Policies/UserPolicyTest.php @@ -2,9 +2,9 @@ namespace Tests\Unit\Policies; +use Tests\TestCase; use App\Entities\Users\User; use App\Entities\Projects\Job; -use Tests\TestCase as TestCase; use App\Entities\Payments\Payment; use Illuminate\Foundation\Testing\DatabaseMigrations; diff --git a/tests/Unit/Policies/VendorPolicyTest.php b/tests/Unit/Policies/VendorPolicyTest.php index eeecaa5..35274f8 100644 --- a/tests/Unit/Policies/VendorPolicyTest.php +++ b/tests/Unit/Policies/VendorPolicyTest.php @@ -5,6 +5,7 @@ namespace Tests\Unit\Policies; use Tests\TestCase; use App\Entities\Partners\Vendor; use App\Entities\Payments\Payment; +use Illuminate\Foundation\Testing\DatabaseMigrations; /** * Vendor Policy Test. @@ -13,6 +14,8 @@ use App\Entities\Payments\Payment; */ class VendorPolicyTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function only_admin_can_create_vendor() { diff --git a/tests/Unit/Queries/AdminDashboardQueryTest.php b/tests/Unit/Queries/AdminDashboardQueryTest.php index 52d352b..4b79024 100644 --- a/tests/Unit/Queries/AdminDashboardQueryTest.php +++ b/tests/Unit/Queries/AdminDashboardQueryTest.php @@ -10,9 +10,12 @@ use App\Entities\Payments\Payment; use App\Entities\Projects\Project; use App\Queries\AdminDashboardQuery; use App\Entities\Subscriptions\Subscription; +use Illuminate\Foundation\Testing\DatabaseMigrations; class AdminDashboardQueryTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function retrieve_total_earnings_on_the_year() { diff --git a/tests/Unit/Services/SiteOptionTest.php b/tests/Unit/Services/SiteOptionTest.php index 43e539d..122d439 100644 --- a/tests/Unit/Services/SiteOptionTest.php +++ b/tests/Unit/Services/SiteOptionTest.php @@ -4,9 +4,12 @@ namespace Tests\Unit\Services; use Option; use Tests\TestCase; +use Illuminate\Foundation\Testing\DatabaseMigrations; class SiteOptionTest extends TestCase { + use DatabaseMigrations; + /** @test */ public function option_can_be_set() {