All usages of (error|warning|success)box CSS classes should be fixed in core.
For example the login and signup special pages have ?error and ?warning URL parameters that can be used to show a custom message, which ends up in this code:
if ( $this->mEntryError ) { $fieldDefinitions['entryError'] = [ 'type' => 'info', 'default' => Html::rawElement( 'div', [ 'class' => $this->mEntryErrorType . 'box', ], $this->mEntryError ), 'raw' => true, 'rawrow' => true, 'weight' => -100, ]; }
$this->mEntryErrorType . 'box' can be errorbox or warningbox. Those classes are going away, see parent task.