Update arch tests
This commit is contained in:
parent
131061a3ee
commit
56090b0104
|
@ -86,7 +86,8 @@
|
||||||
"mockery/mockery": "^1.4.4",
|
"mockery/mockery": "^1.4.4",
|
||||||
"orchestra/testbench": "^9.0",
|
"orchestra/testbench": "^9.0",
|
||||||
"pestphp/pest": "^3.0",
|
"pestphp/pest": "^3.0",
|
||||||
"phpstan/phpstan-mockery": "^2.0"
|
"phpstan/phpstan-mockery": "^2.0",
|
||||||
|
"qossmic/deptrac": "^2.0"
|
||||||
},
|
},
|
||||||
"config": {
|
"config": {
|
||||||
"optimize-autoloader": true,
|
"optimize-autoloader": true,
|
||||||
|
@ -121,6 +122,10 @@
|
||||||
"minimum-stability": "dev",
|
"minimum-stability": "dev",
|
||||||
"prefer-stable": true,
|
"prefer-stable": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
"archtest": [
|
||||||
|
"./vendor/bin/deptrac analyze",
|
||||||
|
"./vendor/bin/pest tests/Arch.php"
|
||||||
|
],
|
||||||
"post-autoload-dump": [
|
"post-autoload-dump": [
|
||||||
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
|
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
|
||||||
"@php artisan package:discover --ansi"
|
"@php artisan package:discover --ansi"
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "7ea50eebeb73984c5cf66105fc42e50b",
|
"content-hash": "65ea356f4d9ce066e39c9914f823db01",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "amphp/amp",
|
"name": "amphp/amp",
|
||||||
|
@ -15724,6 +15724,54 @@
|
||||||
},
|
},
|
||||||
"time": "2024-10-14T03:18:12+00:00"
|
"time": "2024-10-14T03:18:12+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "qossmic/deptrac",
|
||||||
|
"version": "2.0.4",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/qossmic/deptrac.git",
|
||||||
|
"reference": "a6dbfaf4f20f0ae98b766954f35b8c164c3063ed"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/qossmic/deptrac/zipball/a6dbfaf4f20f0ae98b766954f35b8c164c3063ed",
|
||||||
|
"reference": "a6dbfaf4f20f0ae98b766954f35b8c164c3063ed",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"ext-json": "*",
|
||||||
|
"php": "^8.1"
|
||||||
|
},
|
||||||
|
"suggest": {
|
||||||
|
"ext-dom": "For using the JUnit output formatter"
|
||||||
|
},
|
||||||
|
"bin": [
|
||||||
|
"bin/deptrac",
|
||||||
|
"deptrac.phar"
|
||||||
|
],
|
||||||
|
"type": "library",
|
||||||
|
"autoload": {
|
||||||
|
"files": [
|
||||||
|
"bootstrap.php"
|
||||||
|
],
|
||||||
|
"psr-4": {
|
||||||
|
"Qossmic\\Deptrac\\": "src/"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"description": "Deptrac is a static code analysis tool that helps to enforce rules for dependencies between software layers.",
|
||||||
|
"keywords": [
|
||||||
|
"static analysis"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"source": "https://github.com/qossmic/deptrac/tree/2.0.4"
|
||||||
|
},
|
||||||
|
"abandoned": "deptrac/deptrac",
|
||||||
|
"time": "2024-11-21T22:38:34+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/polyfill-php84",
|
"name": "symfony/polyfill-php84",
|
||||||
"version": "v1.31.0",
|
"version": "v1.31.0",
|
||||||
|
|
|
@ -0,0 +1,30 @@
|
||||||
|
deptrac:
|
||||||
|
paths:
|
||||||
|
- ./app
|
||||||
|
- ./modules
|
||||||
|
exclude_files:
|
||||||
|
- '#.*Test.php$#'
|
||||||
|
layers:
|
||||||
|
- name: AppFiles
|
||||||
|
collectors:
|
||||||
|
- type: bool
|
||||||
|
must:
|
||||||
|
- type: classLike
|
||||||
|
value: .*
|
||||||
|
- type: directory
|
||||||
|
value: app/.*
|
||||||
|
|
||||||
|
- name: ModuleFiles
|
||||||
|
collectors:
|
||||||
|
- type: bool
|
||||||
|
must:
|
||||||
|
- type: classLike
|
||||||
|
value: .*
|
||||||
|
- type: directory
|
||||||
|
value: modules/.*
|
||||||
|
|
||||||
|
ruleset:
|
||||||
|
ModuleFiles:
|
||||||
|
- AppFiles
|
||||||
|
AppFiles:
|
||||||
|
- ModuleFiles
|
|
@ -4,3 +4,8 @@ arch()
|
||||||
->expect('App')
|
->expect('App')
|
||||||
->not->toUse(['die', 'dd', 'dump'])
|
->not->toUse(['die', 'dd', 'dump'])
|
||||||
->not->toHaveFileSystemPermissions('0777');
|
->not->toHaveFileSystemPermissions('0777');
|
||||||
|
|
||||||
|
arch()
|
||||||
|
->expect('Modules')
|
||||||
|
->not->toUse(['die', 'dd', 'dump'])
|
||||||
|
->not->toHaveFileSystemPermissions('0777');
|
||||||
|
|
Loading…
Reference in New Issue