From 6c876b711cdd8abd029e0d18e92dac3f67182e98 Mon Sep 17 00:00:00 2001 From: William Allen <16820599+williamjallen@users.noreply.github.com> Date: Fri, 3 Jan 2025 08:44:38 -0500 Subject: [PATCH 1/2] Remove `laravel/legacy-factories` dependency --- composer.json | 1 - composer.lock | 58 +-------------------------------------------------- 2 files changed, 1 insertion(+), 58 deletions(-) diff --git a/composer.json b/composer.json index 9951ed096..d96419b74 100644 --- a/composer.json +++ b/composer.json @@ -30,7 +30,6 @@ "http-interop/http-factory-guzzle": "1.2.0", "knplabs/github-api": "3.16.0", "laravel/framework": "10.48.23", - "laravel/legacy-factories": "1.4.0", "laravel/socialite": "5.16.1", "laravel/ui": "4.6.0", "lcobucci/jwt": "5.4.2", diff --git a/composer.lock b/composer.lock index ef743ab50..6d4acf90d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "ed9a56e6e2ffff462d5947b39ed9de9e", + "content-hash": "409734b5fa6dd2794fd9a3a84bf84102", "packages": [ { "name": "24slides/laravel-saml2", @@ -2348,62 +2348,6 @@ }, "time": "2024-11-12T15:39:10+00:00" }, - { - "name": "laravel/legacy-factories", - "version": "v1.4.0", - "source": { - "type": "git", - "url": "https://github.com/laravel/legacy-factories.git", - "reference": "6cb79f668fc36b8b396ada1da3ba45867889c30f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laravel/legacy-factories/zipball/6cb79f668fc36b8b396ada1da3ba45867889c30f", - "reference": "6cb79f668fc36b8b396ada1da3ba45867889c30f", - "shasum": "" - }, - "require": { - "illuminate/macroable": "^8.0|^9.0|^10.0|^11.0", - "php": "^7.3|^8.0", - "symfony/finder": "^3.4|^4.0|^5.0|^6.0|^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - }, - "laravel": { - "providers": [ - "Illuminate\\Database\\Eloquent\\LegacyFactoryServiceProvider" - ] - } - }, - "autoload": { - "files": [ - "helpers.php" - ], - "psr-4": { - "Illuminate\\Database\\Eloquent\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Taylor Otwell", - "email": "taylor@laravel.com" - } - ], - "description": "The legacy version of the Laravel Eloquent factories.", - "homepage": "http://laravel.com", - "support": { - "issues": "https://github.com/laravel/framework/issues", - "source": "https://github.com/laravel/framework" - }, - "time": "2024-01-15T13:55:14+00:00" - }, { "name": "laravel/prompts", "version": "v0.1.25", From 4893917d3e4f957d462ebe3e164b779572df6cdc Mon Sep 17 00:00:00 2001 From: William Allen <16820599+williamjallen@users.noreply.github.com> Date: Fri, 3 Jan 2025 08:48:11 -0500 Subject: [PATCH 2/2] Remove last usage of legacy `factory()` method --- app/cdash/tests/kwtest/kw_web_tester.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/cdash/tests/kwtest/kw_web_tester.php b/app/cdash/tests/kwtest/kw_web_tester.php index 2593b3829..086a410fa 100644 --- a/app/cdash/tests/kwtest/kw_web_tester.php +++ b/app/cdash/tests/kwtest/kw_web_tester.php @@ -311,7 +311,7 @@ public function createUser(array $fields = []) $fields['password'] = password_hash($fields['password'], PASSWORD_DEFAULT); } - $user = factory(User::class)->create($fields); + $user = User::create($fields); return $user; }