Issues (138)

tests/Renderer/Bootstrap4Test.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Nip\Form\Tests\Renderer;
4
5
use Nip\Form\Form;
6
use Nip\Form\Tests\AbstractTest;
7
8
/**
9
 * Class Bootstrap4Test
10
 * @package Nip\Form\Tests\Renderer
11
 */
12
class Bootstrap4Test extends AbstractTest
13
{
14
    public function testRenderRow()
15
    {
16
        $form = new Form();
17
        $form->setRendererType('Bootstrap4');
18
        $form->add('test_input');
19
20
        self::assertSame(
21
            '<div class="form-group row-test_input">'
22
            . '<label class="col-form-label ">Test_input:</label>'
23
            . '<div class=""><input  type="text" name="test_input" class="form-control " title="Test_input" />'
24
            . '</div>'
25
            . '</div>',
26
            $form->getRenderer()->renderRow($form->getElement('test_input'))
0 ignored issues
show
The method renderRow() does not exist on Nip_Form_Renderer_Basic. Did you maybe mean renderRows()? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

26
            $form->getRenderer()->/** @scrutinizer ignore-call */ renderRow($form->getElement('test_input'))

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
27
        );
28
    }
29
}
30