Task #85025

Enumerations must be final

Added by Mathias Brodala over 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
Must have
Category:
Code Cleanup
Target version:
Start date:
2018-05-16
Due date:
% Done:

100%

TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
easy
Sprint Focus:

Description

All Enumeration classes in TYPO3 must be marked as final. It does not make sense to have these extendable since the code which uses these expects a know set of values, adding more values leads to undefined behavior, thus bugs.

Associated revisions

Revision 8cb9506b (diff)
Added by Mathias Brodala over 1 year ago

[!!!][TASK] Make all enumerations final

Code which uses enumerations expects a known set of values, adding
more values by extending these classes leads to undefined behavior.

Since it is now impossible to create a mock of an enumeration also
drop a few Enumeration tests and stick to testing of the public API.

Resolves: #85025
Releases: master
Change-Id: I3d0238c85ae916052dc1aa503f7f8e39c1765ac6
Reviewed-on: https://review.typo3.org/56976
Tested-by: TYPO3com <>
Reviewed-by: Joerg Boesche <>
Reviewed-by: Anja Leichsenring <>
Tested-by: Anja Leichsenring <>
Reviewed-by: Mona Muzaffar <>
Tested-by: Mona Muzaffar <>
Tested-by: Jan Helke <>
Reviewed-by: Jan Helke <>
Reviewed-by: Andreas Fernandez <>
Tested-by: Andreas Fernandez <>

History

#1 Updated by Gerrit Code Review over 1 year 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/56976

#2 Updated by Gerrit Code Review over 1 year ago

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

#3 Updated by Gerrit Code Review over 1 year ago

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

#4 Updated by Gerrit Code Review over 1 year ago

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

#5 Updated by Gerrit Code Review over 1 year ago

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

#6 Updated by Gerrit Code Review over 1 year ago

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

#7 Updated by Gerrit Code Review over 1 year ago

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

#8 Updated by Mathias Brodala over 1 year ago

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

#9 Updated by Benni Mack about 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF