Example #1
0
 /**
  * Prepares the data to be validated.
  *
  * @return array
  */
 protected function prepareValidationData()
 {
     $driver = $this->repository->getDatabaseDriver();
     $databaseData = [];
     foreach ($this->repository->getDatabaseData($driver) as $field => $value) {
         $databaseData["{$driver}.{$field}"] = $value;
     }
     return array_merge($this->repository->getUserData(), $databaseData);
 }
Example #2
0
 /** @test */
 public function it_can_set_the_user_data()
 {
     $this->repository->setUserData(['email' => '*****@*****.**', 'password' => 'secret', 'password_confirm' => 'secret']);
     $this->assertNotEmpty(array_filter($this->repository->getUserData()));
 }