Opened 4 months ago
#53364 new task (blessed)
Tests: Reduce usage of assertEquals for 5.9
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 5.9 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Build/Test Tools | Keywords: | needs-unit-tests php8 |
Focuses: | Cc: |
Description
Follow-up to:
The assertEquals()
test method does not check that the types of the expected and actual values match. This can hide subtle bugs especially when the values are falsey.
Tasks:
- Switch to using
assertSame()
when the type of the value in the assertion is important - Replace overall usage of
assertEquals()
with type-strict assertion methods, with the aim of potentially removing its usage altogether
Note: See
TracTickets for help on using
tickets.