Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[PhpUnitBridge] Baseline generation includes deprecations triggered in legacy tests #46710

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
mondrake opened this issue Jun 18, 2022 · 0 comments

Comments

@mondrake
Copy link
Contributor

Symfony version(s) affected

6.1.0, but earlier for sure

Description

Baseline generation includes deprecations triggered in legacy tests, which IMHO

  1. is irrelevant, because by design deprecations in that context are ignored since they're explicitly expected to occur
  2. are confusing if included in the baseline file, since they're not really to be addressed by developers

How to reproduce

Create a baseline file for a test class that has at least a test marked legacy and deprecations are triggered as part of that test execution.

Possible Solution

Do not include in deprecation baseline file the Deprecation objects that have ::isLegacy() true.

Additional Context

No response

@mondrake mondrake added the Bug label Jun 18, 2022
nicolas-grekas added a commit that referenced this issue Jun 19, 2022
…ons triggered in legacy test (mondrake)

This PR was submitted for the 6.1 branch but it was merged into the 5.4 branch instead.

Discussion
----------

[PhpUnitBridge] Exclude from baseline generation deprecations triggered in legacy test

| Q             | A
| ------------- | ---
| Branch?       | 6.1<!-- see below -->
| Bug fix?      | yes
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets       | Fix #46710  <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead -->
| License       | MIT
<!-- | Doc PR        | symfony/symfony-docs#... required for new features -->
<!--
Replace this notice by a short README for your feature/bugfix.
This will help reviewers and should be a good start for the documentation.

Additionally (see https://symfony.com/releases):
 - Always add tests and ensure they pass.
 - Bug fixes must be submitted against the lowest maintained branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too.)
 - Features and deprecations must be submitted against the latest branch.
 - Changelog entry should follow https://symfony.com/doc/current/contributing/code/conventions.html#writing-a-changelog-entry
 - Never break backward compatibility (see https://symfony.com/bc).
-->

Commits
-------

4f96afe Exclude from baseline generation deprecations triggered in legacy test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants