|
13 | 13 | use Psr\Container\ContainerInterface; |
14 | 14 | use RuntimeException; |
15 | 15 |
|
16 | | -describe('LoggingFactorySpec', function () { |
| 16 | +describe('LoggingFactorySpec', function (): void { |
17 | 17 |
|
18 | 18 | given('factory', fn() => new LoggingFactory()); |
19 | 19 |
|
|
98 | 98 | ], |
99 | 99 | ]); |
100 | 100 |
|
101 | | - describe('__invoke()', function () { |
| 101 | + describe('__invoke()', function (): void { |
102 | 102 |
|
103 | | - it('instance of Logging on non-console with container does not has "Request" service', function () { |
| 103 | + it('instance of Logging on non-console with container does not has "Request" service', function (): void { |
104 | 104 |
|
105 | 105 | Console::overrideIsConsole(false); |
106 | 106 | $config = $this->config; |
|
120 | 120 |
|
121 | 121 | }); |
122 | 122 |
|
123 | | - it('instance of Logging without bring Laminas\Mail\Message and Laminas\Mail\Transport if email-notification-settings is disabled', function () { |
| 123 | + it('instance of Logging without bring Laminas\Mail\Message and Laminas\Mail\Transport if email-notification-settings is disabled', function (): void { |
124 | 124 |
|
125 | 125 | $config = $this->config; |
126 | 126 |
|
|
137 | 137 |
|
138 | 138 | }); |
139 | 139 |
|
140 | | - it('throw RuntimeException if Logging try bring non-existence Laminas\Mail\Message service while email-notification-settings is enabled', function () { |
| 140 | + it('throw RuntimeException if Logging try bring non-existence Laminas\Mail\Message service while email-notification-settings is enabled', function (): void { |
141 | 141 |
|
142 | 142 | $config = $this->config; |
143 | 143 | $config['error-hero-module']['email-notification-settings']['enable'] = true; |
|
150 | 150 | allow($container)->toReceive('get')->with('ErrorHeroModuleLogger') |
151 | 151 | ->andReturn($logger); |
152 | 152 |
|
153 | | - $closure = function () use ($container) { |
| 153 | + $closure = function () use ($container): void { |
154 | 154 | $this->factory($container); |
155 | 155 | }; |
156 | 156 |
|
157 | 157 | expect($closure)->toThrow(new RuntimeException()); |
158 | 158 |
|
159 | 159 | }); |
160 | 160 |
|
161 | | - it('throw RuntimeException if Logging try bring non-existence Laminas\Mail\Transport\TransportInterface service while email-notification-settings is enabled', function () { |
| 161 | + it('throw RuntimeException if Logging try bring non-existence Laminas\Mail\Transport\TransportInterface service while email-notification-settings is enabled', function (): void { |
162 | 162 |
|
163 | 163 | $config = $this->config; |
164 | 164 | $config['error-hero-module']['email-notification-settings']['enable'] = true; |
|
174 | 174 | allow($container)->toReceive('get')->with('MailMessageService') |
175 | 175 | ->andReturn(new Message()); |
176 | 176 |
|
177 | | - $closure = function () use ($container) { |
| 177 | + $closure = function () use ($container): void { |
178 | 178 | $this->factory($container); |
179 | 179 | }; |
180 | 180 |
|
181 | 181 | expect($closure)->toThrow(new RuntimeException()); |
182 | 182 |
|
183 | 183 | }); |
184 | 184 |
|
185 | | - it('instance of Logging with bring Laminas\Mail\Message and Laminas\Mail\Transport if email-notification-settings is enabled and both services exist', function () { |
| 185 | + it('instance of Logging with bring Laminas\Mail\Message and Laminas\Mail\Transport if email-notification-settings is enabled and both services exist', function (): void { |
186 | 186 |
|
187 | 187 | $config = $this->config; |
188 | 188 | $config['error-hero-module']['email-notification-settings']['enable'] = true; |
|
0 commit comments