From 4f22fb98124ffd40ac54f3747d776310c401616f Mon Sep 17 00:00:00 2001 From: Lucas Hedding Date: Mon, 2 Sep 2024 16:17:13 -0600 Subject: [PATCH 1/3] Update phpunit.yml Signed-off-by: Lucas Hedding --- .github/workflows/phpunit.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/phpunit.yml b/.github/workflows/phpunit.yml index 04bb335459..650b687250 100644 --- a/.github/workflows/phpunit.yml +++ b/.github/workflows/phpunit.yml @@ -14,7 +14,7 @@ jobs: strategy: matrix: operating-system: ['ubuntu-22.04','ubuntu-24.04'] - php-versions: ['8.2'] + php-versions: ['8.3'] phpunit-versions: ['latest'] ci_node_total: [ 8 ] ci_node_index: [ 0, 1, 2, 3, 4, 5, 6, 7] From 5b9af52ba1893d7f31d7fdcf3fb0c7fea5d74494 Mon Sep 17 00:00:00 2001 From: Lucas D Hedding Date: Tue, 3 Sep 2024 09:32:29 -0600 Subject: [PATCH 2/3] fix failing tests, resolves https://github.com/laravel/framework/issues/49237 --- tests/Feature/Import/ImportCompanyTest.php | 2 ++ tests/Integration/MultiDBUserTest.php | 2 ++ tests/Integration/UniqueEmailTest.php | 2 ++ 3 files changed, 6 insertions(+) diff --git a/tests/Feature/Import/ImportCompanyTest.php b/tests/Feature/Import/ImportCompanyTest.php index 593f742794..c97c70c486 100644 --- a/tests/Feature/Import/ImportCompanyTest.php +++ b/tests/Feature/Import/ImportCompanyTest.php @@ -1151,6 +1151,8 @@ class ImportCompanyTest extends TestCase protected function tearDown() :void { + parent::tearDown(); + $backup_json_file = sys_get_temp_dir().'/backup/backup.json'; // unlink($backup_json_file); diff --git a/tests/Integration/MultiDBUserTest.php b/tests/Integration/MultiDBUserTest.php index 354cae6ded..03e695374b 100644 --- a/tests/Integration/MultiDBUserTest.php +++ b/tests/Integration/MultiDBUserTest.php @@ -245,6 +245,8 @@ class MultiDBUserTest extends TestCase protected function tearDown() :void { + parent::tearDown(); + DB::connection('db-ninja-01')->table('users')->delete(); DB::connection('db-ninja-02')->table('users')->delete(); diff --git a/tests/Integration/UniqueEmailTest.php b/tests/Integration/UniqueEmailTest.php index 2882879157..1ed32dcf62 100644 --- a/tests/Integration/UniqueEmailTest.php +++ b/tests/Integration/UniqueEmailTest.php @@ -106,6 +106,8 @@ class UniqueEmailTest extends TestCase protected function tearDown() :void { + parent::tearDown(); + DB::connection('db-ninja-01')->table('users')->delete(); DB::connection('db-ninja-02')->table('users')->delete(); } From f9465b6288efc5c24b4b0f390ed9dc16810f186d Mon Sep 17 00:00:00 2001 From: Lucas D Hedding Date: Wed, 4 Sep 2024 08:43:56 -0600 Subject: [PATCH 3/3] attempt to fix failing test --- tests/Feature/TaskStatusApiTest.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/Feature/TaskStatusApiTest.php b/tests/Feature/TaskStatusApiTest.php index 780ba4c12e..1dc93393d1 100644 --- a/tests/Feature/TaskStatusApiTest.php +++ b/tests/Feature/TaskStatusApiTest.php @@ -48,17 +48,18 @@ class TaskStatusApiTest extends TestCase { TaskStatus::factory()->count(5)->create([ 'company_id' => $this->company->id, - 'user_id' => $this->user->id + 'user_id' => $this->user->id, + 'status_order' => 99999, ]); - - + + $t = TaskStatus::where('company_id', '=', $this->company->id)->orderBy('id', 'desc'); - + $this->assertEquals(10, $t->count()); $task_status = $t->first(); $id = $task_status->id; - + nlog("setting {$id} to index 1"); $data = [ @@ -73,7 +74,7 @@ class TaskStatusApiTest extends TestCase $t = TaskStatus::where('company_id', '=', $this->company->id)->orderBy('status_order', 'asc')->first(); $this->assertEquals($id, $t->id); - + } public function testTaskStatusGetFilter()