You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Tests: detect the deprecations and boot a kernel with process-bundle #57
The deprecations are not detected by the test suite: no failOnDeprecation, no symfony/phpunit-bridge, no SYMFONY_DEPRECATIONS_HELPER. The deprecations triggered with trigger_deprecation() are silenced (@trigger_error()), so PHPUnit ignores them by default, and the @final annotations need the DebugClassLoader. A deprecation of Symfony, Doctrine or process-bundle used by this bundle goes unnoticed until the next major.
No test boots a kernel with process-bundle and the third-party bundles: the extension tests load it into a bare ContainerBuilder. The resolution of the task codes by process-bundle's TaskLocatorCompilerPass, the code collisions with the core, and the references to the services of other bundles are only checked by hand in process-bundle-demo.
Proposed fix
Fail the tests on deprecations: failOnDeprecation="true", <source ignoreSuppressionOfDeprecations="true"> restricted to the deprecations caused by this bundle's code (ignoreIndirectDeprecations / ignoreSelfDeprecations, or the phpunit-bridge baseline), DebugClassLoader::enable() in the bootstrap. To check with the lowest supported PHPUnit (10.5) and the lowest CI job; the tests of deprecated features expect their deprecation explicitly.
Add a functional test booting a minimal kernel (FrameworkBundle, process-bundle and this bundle) and compiling the container: every task declared by the bundle is resolvable by its code through the process-bundle registry, and the adapters locator (cleverage.cache.adapter tag, code attribute) resolves.
Same work in process-bundle: cleverage/process-bundle#303. Found during the Symfony bundle best practices review of the bridges.
Activity
#57 - Tests: detect the deprecations and boot a kernel with process-b…
Merge pull request #60 from cleverage/57