mirror of
https://github.com/coollabsio/coolify.git
synced 2026-11-06 16:46:37 +00:00
- Delete Blade components, component classes, Livewire components and views that nothing uses after the redesign. - Delete tests that only compare Blade/CSS source text; keep the source checks for authorization gates, stable wire:key values and escaping. - Update stale tests to the current UI and behaviour. - Update DESIGN.md to the current navigation and layout. - Add a lesson: test behaviour, not source markup. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
23 lines
828 B
PHP
23 lines
828 B
PHP
<?php
|
|
|
|
use Illuminate\Support\Facades\Blade;
|
|
|
|
test('searchable listbox renders its label, search field, and options', function () {
|
|
$html = Blade::render(<<<'BLADE'
|
|
<x-forms.searchable-listbox id="serverTimezone" label="Server timezone"
|
|
searchPlaceholder="Search timezones" emptyText="No matching timezone"
|
|
:options="[
|
|
['value' => 'UTC', 'label' => 'UTC'],
|
|
['value' => 'Europe/Berlin', 'label' => 'Europe/Berlin'],
|
|
['value' => 'America/New_York', 'label' => 'America/New_York'],
|
|
]" :wire="false" value="UTC" />
|
|
BLADE);
|
|
|
|
expect($html)
|
|
->toContain('Server timezone')
|
|
->toContain('Search timezones')
|
|
->toContain('No matching timezone')
|
|
->toContain('Berlin')
|
|
->toContain('New_York');
|
|
});
|