Реорганизованы зависимости для ReCaptcha\Validator

Новый способ отключения проверки капчи для функциональных тестов
This commit is contained in:
ErickSkrauch
2017-05-18 02:09:26 +03:00
parent b9df9ff2a7
commit 0cf68a6360
7 changed files with 113 additions and 147 deletions

View File

@@ -1,4 +1,7 @@
<?php
use api\components\ReCaptcha\Validator;
use GuzzleHttp\Client;
return [
'components' => [
'user' => [
@@ -17,4 +20,15 @@ return [
'params' => [
'authserverHost' => 'authserver.ely.by',
],
'container' => [
'definitions' => [
Validator::class => function() {
return new class(new Client()) extends Validator {
protected function validateValue($value) {
return null;
}
};
},
],
],
];