Bug #88530

phpunit 8.2 breaks Unit Tests

Added by Anja Leichsenring about 1 month ago. Updated about 1 month ago.

Status:
Resolved
Priority:
Should have
Category:
-
Target version:
-
Start date:
2019-06-08
Due date:
% Done:

100%

TYPO3 Version:
10
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

We face another round of upgrades from phpunit 8.1 -> 8.2

https://github.com/sebastianbergmann/phpunit/blob/8.2/ChangeLog-8.2.md

notably changes:

- Exceptions on Mock Objects are not raised anymore, instead an own exceptions is created and thrown
- Return types of method expections are now checked for validity

Associated revisions

Revision 41813a47 (diff)
Added by Anja Leichsenring about 1 month ago

[BUGFIX] Tests broken with phpunit 8.2

Switching from accessibleMock to prophecy resolves
a lot of failures.
Also, using a concrete instance instead accessibleMockForAbstractClass
reduces issues.

Resolves: #88530
Releases: master, 9.5
Change-Id: I102597f74a98443fe139a76b8f168abf61349e3d
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60903
Tested-by: TYPO3com <>
Tested-by: Andreas Fernandez <>
Tested-by: Susanne Moog <>
Reviewed-by: Andreas Fernandez <>
Reviewed-by: Susanne Moog <>

History

#1 Updated by Gerrit Code Review about 1 month ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60903

#2 Updated by Anja Leichsenring about 1 month ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF