]> git.mxchange.org Git - friendica.git/blob - tests/src/Util/Logger/LoggerDataTrait.php
Merge pull request #10104 from nupplaphil/fix/jit_caching
[friendica.git] / tests / src / Util / Logger / LoggerDataTrait.php
1 <?php
2 /**
3  * @copyright Copyright (C) 2020, Friendica
4  *
5  * @license GNU AGPL version 3 or any later version
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU Affero General Public License as
9  * published by the Free Software Foundation, either version 3 of the
10  * License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU Affero General Public License for more details.
16  *
17  * You should have received a copy of the GNU Affero General Public License
18  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
19  *
20  */
21
22 namespace Friendica\Test\src\Util\Logger;
23
24 trait LoggerDataTrait
25 {
26         public function dataTests()
27         {
28                 return [
29                         'emergency' => [
30                                 'function' => 'emergency',
31                                 'message' => 'test',
32                                 'context' => ['a' => 'context'],
33                         ],
34                         'alert' => [
35                                 'function' => 'alert',
36                                 'message' => 'test {test}',
37                                 'context' => ['a' => 'context', 2 => 'so', 'test' => 'works'],
38                         ],
39                         'critical' => [
40                                 'function' => 'critical',
41                                 'message' => 'test crit 2345',
42                                 'context' => ['a' => 'context', 'wit' => ['more', 'array']],
43                         ],
44                         'error' => [
45                                 'function' => 'error',
46                                 'message' => 2.554,
47                                 'context' => [],
48                         ],
49                         'warning' => [
50                                 'function' => 'warning',
51                                 'message' => 'test warn',
52                                 'context' => ['a' => 'context'],
53                         ],
54                         'notice' => [
55                                 'function' => 'notice',
56                                 'message' => 2346,
57                                 'context' => ['a' => 'context'],
58                         ],
59                         'info' => [
60                                 'function' => 'info',
61                                 'message' => null,
62                                 'context' => ['a' => 'context'],
63                         ],
64                         'debug' => [
65                                 'function' => 'debug',
66                                 'message' => true,
67                                 'context' => ['a' => false],
68                         ],
69                 ];
70         }
71 }