Determine if we should add static analysis for weird uses of TestCase

Created on 8 December 2023, about 1 year ago
Updated 26 February 2024, 10 months ago

Problem/Motivation

Followup from 🐛 Remove use of TestClass constructor RTBC .

PHPUnit changes the constructor for the TestCase several times. Its well accepted that logic should be in various setup methods instead of the constructor because its internal and the signature is subject to change but core instantiates TestCases's directly in some places which also breaks. This can cause testing errors or potential strange behaviors when TestCase is used or constructed in unusual ways.

Proposed resolution

Determine if static analysis can be added (or requested from upstream) to catch these sorts of odd uses of the class so they don't introduce false passes or strange test behaviors.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

📌 Task
Status

Active

Version

11.0 🔥

Component
PHPUnit 

Last updated 1 day ago

Created by

🇺🇸United States xjm

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024