From a1f9d2dc98935fcfe34b84836f0a1a6460759fc1 Mon Sep 17 00:00:00 2001 From: Ruslan Guskov Date: Sat, 17 May 2025 15:59:47 +0300 Subject: [PATCH 1/2] chore:update helpers package --- composer.json | 2 +- composer.lock | 168 ++++++++---------- stubs/nova_test.blade.php | 2 +- stubs/test.blade.php | 2 +- tests/fixtures/CommandTest/factory.php | 1 - tests/fixtures/CommandTest/nova_test.php | 2 +- tests/fixtures/CommandTest/test.php | 2 +- .../created_resource_test.php | 2 +- .../fixtures/TestGeneratorTest/post_test.php | 2 +- .../post_test_read_delete.php | 2 +- 10 files changed, 82 insertions(+), 103 deletions(-) diff --git a/composer.json b/composer.json index 1c8cb636..59c9a1a2 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,7 @@ "require": { "php": "^8.3", "laravel/framework": ">=11.31.0", - "ronasit/laravel-helpers": "^3.0.1-beta", + "ronasit/laravel-helpers": ">=3.4", "laravel/legacy-factories": ">=1.4.0", "ext-json": "*", "doctrine/dbal": "^4.2" diff --git a/composer.lock b/composer.lock index 9d9e46a3..f1bfcec8 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": "0e6d7ad33208420eeaf095f3b0d31718", + "content-hash": "06b28df5fc599471a59b373705d00f71", "packages": [ { "name": "brick/math", @@ -4799,28 +4799,85 @@ ], "time": "2024-04-27T21:32:50+00:00" }, + { + "name": "riverline/multipart-parser", + "version": "2.2.0", + "source": { + "type": "git", + "url": "https://github.com/Riverline/multipart-parser.git", + "reference": "1410f23a8fd416a0cf5c8867ea9c95544016c831" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Riverline/multipart-parser/zipball/1410f23a8fd416a0cf5c8867ea9c95544016c831", + "reference": "1410f23a8fd416a0cf5c8867ea9c95544016c831", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": ">=5.6.0" + }, + "require-dev": { + "laminas/laminas-diactoros": "^1.8.7 || ^2.11.1", + "phpunit/phpunit": "^5.7 || ^9.0", + "psr/http-message": "^1.0", + "symfony/psr-http-message-bridge": "^1.1 || ^2.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Riverline\\MultiPartParser\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Romain Cambien", + "email": "romain@cambien.net" + }, + { + "name": "Riverline", + "homepage": "http://www.riverline.fr" + } + ], + "description": "One class library to parse multipart content with encoding and charset support.", + "keywords": [ + "http", + "multipart", + "parser" + ], + "support": { + "issues": "https://github.com/Riverline/multipart-parser/issues", + "source": "https://github.com/Riverline/multipart-parser/tree/2.2.0" + }, + "time": "2025-04-29T08:38:14+00:00" + }, { "name": "ronasit/laravel-helpers", - "version": "3.0.1-beta", + "version": "3.4.1", "source": { "type": "git", "url": "https://github.com/RonasIT/laravel-helpers.git", - "reference": "5bf2992029c1f71269d0fddd036a102822399925" + "reference": "997141b533877508e074263a1cf92fa1664816a9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/RonasIT/laravel-helpers/zipball/5bf2992029c1f71269d0fddd036a102822399925", - "reference": "5bf2992029c1f71269d0fddd036a102822399925", + "url": "https://api.github.com/repos/RonasIT/laravel-helpers/zipball/997141b533877508e074263a1cf92fa1664816a9", + "reference": "997141b533877508e074263a1cf92fa1664816a9", "shasum": "" }, "require": { + "doctrine/dbal": "^4.2", "ext-json": "*", "guzzlehttp/guzzle": "^7.9.2", - "laravel/framework": "^11.20", + "laravel/framework": ">=11.20", "maatwebsite/excel": "^3.1.55", "php": ">=8.3", "php-mock/php-mock-phpunit": "^2.10", - "tecnickcom/tcpdf": "^6.7.5" + "riverline/multipart-parser": "^2.1" }, "require-dev": { "brainmaestro/composer-git-hooks": "^3.0", @@ -4834,11 +4891,6 @@ }, "type": "library", "extra": { - "laravel": { - "providers": [ - "RonasIT\\Support\\HelpersServiceProvider" - ] - }, "hooks": { "config": { "stop-on-failure": [ @@ -4848,6 +4900,11 @@ "pre-commit": [ "docker-compose up -d php && docker-compose exec -T php vendor/bin/php-cs-fixer fix && docker-compose exec -T php vendor/bin/tlint" ] + }, + "laravel": { + "providers": [ + "RonasIT\\Support\\HelpersServiceProvider" + ] } }, "autoload": { @@ -4855,9 +4912,7 @@ "src/helpers.php" ], "psr-4": { - "RonasIT\\Support\\": "src/", - "RonasIT\\Support\\Tests\\": "tests/", - "RonasIT\\Support\\Tests\\Support\\": "tests/support/" + "RonasIT\\Support\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -4877,9 +4932,9 @@ ], "support": { "issues": "https://github.com/RonasIT/laravel-helpers/issues", - "source": "https://github.com/RonasIT/laravel-helpers/tree/3.0.1-beta" + "source": "https://github.com/RonasIT/laravel-helpers/tree/3.4.1" }, - "time": "2024-11-04T10:52:30+00:00" + "time": "2025-04-30T14:00:55+00:00" }, { "name": "sebastian/cli-parser", @@ -8025,79 +8080,6 @@ ], "time": "2025-01-17T11:39:41+00:00" }, - { - "name": "tecnickcom/tcpdf", - "version": "6.8.0", - "source": { - "type": "git", - "url": "https://github.com/tecnickcom/TCPDF.git", - "reference": "14ffa0e308f5634aa2489568b4b90b24073b6731" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/tecnickcom/TCPDF/zipball/14ffa0e308f5634aa2489568b4b90b24073b6731", - "reference": "14ffa0e308f5634aa2489568b4b90b24073b6731", - "shasum": "" - }, - "require": { - "ext-curl": "*", - "php": ">=7.1.0" - }, - "type": "library", - "autoload": { - "classmap": [ - "config", - "include", - "tcpdf.php", - "tcpdf_parser.php", - "tcpdf_import.php", - "tcpdf_barcodes_1d.php", - "tcpdf_barcodes_2d.php", - "include/tcpdf_colors.php", - "include/tcpdf_filters.php", - "include/tcpdf_font_data.php", - "include/tcpdf_fonts.php", - "include/tcpdf_images.php", - "include/tcpdf_static.php", - "include/barcodes/datamatrix.php", - "include/barcodes/pdf417.php", - "include/barcodes/qrcode.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-3.0-or-later" - ], - "authors": [ - { - "name": "Nicola Asuni", - "email": "info@tecnick.com", - "role": "lead" - } - ], - "description": "TCPDF is a PHP class for generating PDF documents and barcodes.", - "homepage": "http://www.tcpdf.org/", - "keywords": [ - "PDFD32000-2008", - "TCPDF", - "barcodes", - "datamatrix", - "pdf", - "pdf417", - "qrcode" - ], - "support": { - "issues": "https://github.com/tecnickcom/TCPDF/issues", - "source": "https://github.com/tecnickcom/TCPDF/tree/6.8.0" - }, - "funding": [ - { - "url": "https://www.paypal.com/cgi-bin/webscr?cmd=_donations¤cy_code=GBP&business=paypal@tecnick.com&item_name=donation%20for%20tcpdf%20project", - "type": "custom" - } - ], - "time": "2024-12-23T13:34:57+00:00" - }, { "name": "theseer/tokenizer", "version": "1.2.3", @@ -10672,9 +10654,7 @@ ], "aliases": [], "minimum-stability": "beta", - "stability-flags": { - "ronasit/laravel-helpers": 10 - }, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, "platform": { @@ -10682,5 +10662,5 @@ "ext-json": "*" }, "platform-dev": [], - "plugin-api-version": "2.3.0" + "plugin-api-version": "2.6.0" } diff --git a/stubs/nova_test.blade.php b/stubs/nova_test.blade.php index e89cc043..50f7a46c 100644 --- a/stubs/nova_test.blade.php +++ b/stubs/nova_test.blade.php @@ -2,7 +2,7 @@ use App\Models\{{$entity}}; use PHPUnit\Framework\Attributes\DataProvider; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Traits\NovaTestTrait; class Nova{{$entity}}Test extends TestCase diff --git a/stubs/test.blade.php b/stubs/test.blade.php index 068cc570..c4eb43c3 100644 --- a/stubs/test.blade.php +++ b/stubs/test.blade.php @@ -1,7 +1,7 @@ namespace App\Tests; @if ($hasModificationEndpoints && (!$withAuth || $entity !== 'User')) -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use {{$modelsNamespace}}\{{$entity}}; @endif @if ($withAuth) diff --git a/tests/fixtures/CommandTest/factory.php b/tests/fixtures/CommandTest/factory.php index 9b31f8a5..141edaa2 100644 --- a/tests/fixtures/CommandTest/factory.php +++ b/tests/fixtures/CommandTest/factory.php @@ -2,7 +2,6 @@ namespace RonasIT\Support\Tests\Support\Command\Factories; -use Faker\Generator as Faker; use Illuminate\Database\Eloquent\Factories\Factory; use RonasIT\Support\Tests\Support\Command\Models\Post; diff --git a/tests/fixtures/CommandTest/nova_test.php b/tests/fixtures/CommandTest/nova_test.php index 6a7a0b75..fa304c3d 100644 --- a/tests/fixtures/CommandTest/nova_test.php +++ b/tests/fixtures/CommandTest/nova_test.php @@ -4,7 +4,7 @@ use App\Models\Post; use PHPUnit\Framework\Attributes\DataProvider; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Traits\NovaTestTrait; class NovaPostTest extends TestCase diff --git a/tests/fixtures/CommandTest/test.php b/tests/fixtures/CommandTest/test.php index d36cd53a..24219fb8 100644 --- a/tests/fixtures/CommandTest/test.php +++ b/tests/fixtures/CommandTest/test.php @@ -2,7 +2,7 @@ namespace App\Tests; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Tests\Support\Command\Models\Post; use PHPUnit\Framework\Attributes\DataProvider; diff --git a/tests/fixtures/NovaTestGeneratorTest/created_resource_test.php b/tests/fixtures/NovaTestGeneratorTest/created_resource_test.php index fa08b187..ec6e6543 100644 --- a/tests/fixtures/NovaTestGeneratorTest/created_resource_test.php +++ b/tests/fixtures/NovaTestGeneratorTest/created_resource_test.php @@ -4,7 +4,7 @@ use App\Models\WelcomeBonus; use PHPUnit\Framework\Attributes\DataProvider; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Traits\NovaTestTrait; class NovaWelcomeBonusTest extends TestCase diff --git a/tests/fixtures/TestGeneratorTest/post_test.php b/tests/fixtures/TestGeneratorTest/post_test.php index 876f67d3..dcc066b8 100644 --- a/tests/fixtures/TestGeneratorTest/post_test.php +++ b/tests/fixtures/TestGeneratorTest/post_test.php @@ -2,7 +2,7 @@ namespace App\Tests; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Tests\Support\Test\Models\Post; use RonasIT\Support\Tests\Support\Test\Models\User; use PHPUnit\Framework\Attributes\DataProvider; diff --git a/tests/fixtures/TestGeneratorTest/post_test_read_delete.php b/tests/fixtures/TestGeneratorTest/post_test_read_delete.php index 89f40e8b..89635966 100644 --- a/tests/fixtures/TestGeneratorTest/post_test_read_delete.php +++ b/tests/fixtures/TestGeneratorTest/post_test_read_delete.php @@ -2,7 +2,7 @@ namespace App\Tests; -use RonasIT\Support\Tests\ModelTestState; +use RonasIT\Support\Testing\ModelTestState; use RonasIT\Support\Tests\Support\Test\Models\Post; use RonasIT\Support\Tests\Support\Test\Models\User; use PHPUnit\Framework\Attributes\DataProvider; From 6ff11ff4a019305a9245852eade417531df65c3c Mon Sep 17 00:00:00 2001 From: Ruslan Guskov Date: Sat, 17 May 2025 16:11:21 +0300 Subject: [PATCH 2/2] fix:tests --- tests/fixtures/CommandTest/factory.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/fixtures/CommandTest/factory.php b/tests/fixtures/CommandTest/factory.php index 141edaa2..9b31f8a5 100644 --- a/tests/fixtures/CommandTest/factory.php +++ b/tests/fixtures/CommandTest/factory.php @@ -2,6 +2,7 @@ namespace RonasIT\Support\Tests\Support\Command\Factories; +use Faker\Generator as Faker; use Illuminate\Database\Eloquent\Factories\Factory; use RonasIT\Support\Tests\Support\Command\Models\Post;