◆ errorCollectionProvider()
static ilMailErrorFormatterTest::errorCollectionProvider |
( |
| ) |
|
|
static |
Definition at line 51 of file ilMailErrorFormatterTest.php.
58 'Exactly one error' => [
64 'error1<ul><li>error2</li></ul>' 66 'More than two errors with placeholders' => [
68 'error1<ul><li>error2</li><li>error3 (1. a/2. b/3. c)</li></ul>'
◆ setUp()
ilMailErrorFormatterTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 27 of file ilMailErrorFormatterTest.php.
References ilMailBaseTestCase\setGlobalVariable().
31 $component_factory = $this->getMockBuilder(ilComponentFactory::class)->getMock();
35 $language_mock = $this->getMockBuilder(ilLanguage::class)->disableOriginalConstructor()->getMock();
36 $language_mock->method(
'txt')->willReturnCallback(
static function (
string $key):
string {
37 if ($key ===
'error1') {
38 return '-' . $key .
'-';
41 if ($key ===
'error3') {
42 return $key .
' (1. %s/2. %s/3. %s)';
setGlobalVariable(string $name, $value)
◆ testErrorFormatter()
ilMailErrorFormatterTest::testErrorFormatter |
( |
array |
$errors, |
|
|
string |
$exteced_html |
|
) |
| |
◆ $error_formatter
The documentation for this class was generated from the following file: