Skip to content

Commit

Permalink
Update deptrac
Browse files Browse the repository at this point in the history
  • Loading branch information
jakzal committed Dec 18, 2022
1 parent 95ec165 commit 15a7f97
Show file tree
Hide file tree
Showing 3 changed files with 103 additions and 101 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
/composer.lock
/tests/phar/.phpunit.result.cache
/vendor/
/.deptrac.cache
/.php_cs.cache
/.phpunit.result.cache
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ tools/php-cs-fixer:
curl -Ls http://cs.symfony.com/download/php-cs-fixer-v2.phar -o tools/php-cs-fixer && chmod +x tools/php-cs-fixer

tools/deptrac:
curl -Ls https://github.com/sensiolabs-de/deptrac/releases/download/0.19.1/deptrac.phar -o tools/deptrac && chmod +x tools/deptrac
curl -Ls https://github.com/sensiolabs-de/deptrac/releases/download/0.24.0/deptrac.phar -o tools/deptrac && chmod +x tools/deptrac

tools/infection: tools/infection.pubkey
curl -Ls https://github.com/infection/infection/releases/download/0.26.2/infection.phar -o tools/infection && chmod +x tools/infection
Expand Down
201 changes: 101 additions & 100 deletions deptrac.yaml
Original file line number Diff line number Diff line change
@@ -1,100 +1,101 @@
paths:
- ./src
exclude_files: ~
layers:
- name: Symfony Compiler
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\Symfony\\Compiler\\.*
- name: Symfony TestCase
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\Symfony\\TestCase\\.*
- name: TestCase
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\TestCase\\.*
- name: TestListener
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\TestListener\\.*
- name: Injector Service
collectors:
- type: className
regex: ^Zalas\\Injector\\Service\\.*
- name: Injector Factory
collectors:
- type: className
regex: ^Zalas\\Injector\\Factory\\.*
- name: Psr Container
collectors:
- type: className
regex: ^Psr\\Container\\.*
- name: Symfony Config
collectors:
- type: className
regex: ^Symfony\\Component\\Config\\.*
- name: Symfony DependencyInjection
collectors:
- type: className
regex: ^Symfony\\Component\\DependencyInjection\\.*
- name: Symfony HttpKernel
collectors:
- type: className
regex: ^Symfony\\Component\\HttpKernel\\.*
- name: Symfony Service Contracts
collectors:
- type: className
regex: ^Symfony\\Contracts\\Service\\.*
- name: PHPUnit
collectors:
- type: className
regex: ^PHPUnit\\Framework\\.*
- name: Other Vendors
collectors:
- type: bool
must:
# must be outside of global namespace
- type: className
regex: '[\\]+'
must_not:
# must not be one of the known vendors
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\.*
- type: className
regex: ^Zalas\\Injector\\Service\\.*
- type: className
regex: ^Zalas\\Injector\\Factory\\.*
- type: className
regex: ^Psr\\Container\\.*
- type: className
regex: ^PHPUnit\\Framework\\.*
- type: className
regex: ^Symfony\\Component\\Config\\.*
- type: className
regex: ^Symfony\\Component\\DependencyInjection\\.*
- type: className
regex: ^Symfony\\Component\\HttpKernel\\.*
- type: className
regex: ^Symfony\\Contracts\\Service\\.*
ruleset:
Symfony Compiler:
- Injector Factory
- Injector Service
- PHPUnit
- TestCase
- Symfony Config
- Symfony DependencyInjection
Symfony TestCase:
- Psr Container
- Symfony DependencyInjection
- Symfony HttpKernel
- Symfony Service Contracts
TestCase:
- Psr Container
TestListener:
- TestCase
- Injector Service
- Injector Factory
- Psr Container
- PHPUnit
parameters:
paths:
- ./src
exclude_files: []
layers:
- name: Symfony Compiler
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\Symfony\\Compiler\\.*
- name: Symfony TestCase
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\Symfony\\TestCase\\.*
- name: TestCase
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\TestCase\\.*
- name: TestListener
collectors:
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\TestListener\\.*
- name: Injector Service
collectors:
- type: className
regex: ^Zalas\\Injector\\Service\\.*
- name: Injector Factory
collectors:
- type: className
regex: ^Zalas\\Injector\\Factory\\.*
- name: Psr Container
collectors:
- type: className
regex: ^Psr\\Container\\.*
- name: Symfony Config
collectors:
- type: className
regex: ^Symfony\\Component\\Config\\.*
- name: Symfony DependencyInjection
collectors:
- type: className
regex: ^Symfony\\Component\\DependencyInjection\\.*
- name: Symfony HttpKernel
collectors:
- type: className
regex: ^Symfony\\Component\\HttpKernel\\.*
- name: Symfony Service Contracts
collectors:
- type: className
regex: ^Symfony\\Contracts\\Service\\.*
- name: PHPUnit
collectors:
- type: className
regex: ^PHPUnit\\Framework\\.*
- name: Other Vendors
collectors:
- type: bool
must:
# must be outside of global namespace
- type: className
regex: '[\\]+'
must_not:
# must not be one of the known vendors
- type: className
regex: ^Zalas\\Injector\\PHPUnit\\.*
- type: className
regex: ^Zalas\\Injector\\Service\\.*
- type: className
regex: ^Zalas\\Injector\\Factory\\.*
- type: className
regex: ^Psr\\Container\\.*
- type: className
regex: ^PHPUnit\\Framework\\.*
- type: className
regex: ^Symfony\\Component\\Config\\.*
- type: className
regex: ^Symfony\\Component\\DependencyInjection\\.*
- type: className
regex: ^Symfony\\Component\\HttpKernel\\.*
- type: className
regex: ^Symfony\\Contracts\\Service\\.*
ruleset:
Symfony Compiler:
- Injector Factory
- Injector Service
- PHPUnit
- TestCase
- Symfony Config
- Symfony DependencyInjection
Symfony TestCase:
- Psr Container
- Symfony DependencyInjection
- Symfony HttpKernel
- Symfony Service Contracts
TestCase:
- Psr Container
TestListener:
- TestCase
- Injector Service
- Injector Factory
- Psr Container
- PHPUnit

0 comments on commit 15a7f97

Please sign in to comment.