Download tests/Unit/Blade/FormElementsTest.php from pnacorp/magicai: direct link, hf CLI and curl.
- Browser
- Download file 577 Bytes
-
https://huggingface.co/pnacorp/magicai/resolve/main/tests/Unit/Blade/FormElementsTest.php
- Command line
-
hf download hf://pnacorp/magicai/tests/Unit/Blade/FormElementsTest.php
-
curl -L -o FormElementsTest.php https://huggingface.co/pnacorp/magicai/resolve/main/tests/Unit/Blade/FormElementsTest.php
577 Bytes
| declare(strict_types=1); | |
| test('text', function () { | |
| $expectedValue = <<<'HTML' | |
| <input class="form-control" name="foo" | |
| :id="$id('text-input')" | |
| type="text" | |
| /> | |
| HTML; | |
| expect($this->blade('<x-form.text name="foo" />'))->seeHtml($expectedValue); | |
| }); | |
| test('text for livewire', function () { | |
| $expectedValue = <<<'HTML' | |
| <input class="form-control" wire:model="foo.bar" | |
| :id="$id('text-input')" | |
| type="text" | |
| /> | |
| HTML; | |
| expect($this->blade($expectedValue))->seeHtml($expectedValue); | |
| }); | |