summaryrefslogtreecommitdiff
path: root/tests/Unit/Http/Validation/Stub/ValidatesRequestImplementation.php
blob: 772b1dc9b0caca5b10955fe53f3b945306909fe9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php

namespace Engelsystem\Test\Unit\Http\Validation\Stub;

use Engelsystem\Controllers\BaseController;
use Engelsystem\Http\Request;

class ValidatesRequestImplementation extends BaseController
{
    /**
     * @param Request $request
     * @param array   $rules
     * @return array
     */
    public function validateData(Request $request, array $rules)
    {
        return $this->validate($request, $rules);
    }

    /**
     * @return bool
     */
    public function hasValidator()
    {
        return !is_null($this->validator);
    }
}