Ejemplo n.º 1
0
 /**
  * Test Global Validation with block of non existing params
  *
  * @return void
  */
 public function testGlobalValidationWithBlockOfNonExistingParams()
 {
     $validator = new GlobalValidator();
     $data = ['lang' => 'non-existing-lang', 'theme' => 'non-existing-theme', 'type' => 'non-existing-type', 'size' => 'non-existing-size'];
     $errors = $validator->errors($data);
     $this->assertArrayHasKey('lang', $errors);
     $this->assertArrayHasKey('theme', $errors);
     $this->assertArrayHasKey('type', $errors);
     $this->assertArrayHasKey('size', $errors);
 }
Ejemplo n.º 2
0
 /**
  * Constructor
  *
  * @return void
  */
 public function __construct()
 {
     parent::__construct();
 }
Ejemplo n.º 3
0
 /**
  * Constructor
  *
  * @return void
  */
 public function __construct()
 {
     parent::__construct();
     $this->requirePresence('secret')->notEmpty('secret', __d('recaptcha', 'A secret should not be blank.'));
 }