Changeset View
Changeset View
Standalone View
Standalone View
src/tests/Browser/Components/ListInput.php
Show First 20 Lines • Show All 78 Lines • ▼ Show 20 Lines | class ListInput extends BaseComponent | ||||
} | } | ||||
/** | /** | ||||
* Remove list entry | * Remove list entry | ||||
*/ | */ | ||||
public function removeListEntry($browser, int $num) | public function removeListEntry($browser, int $num) | ||||
{ | { | ||||
$selector = '.input-group:nth-child(' . ($num + 1) . ') a.btn'; | $selector = '.input-group:nth-child(' . ($num + 1) . ') a.btn'; | ||||
$browser->click($selector)->assertMissing($selector); | $browser->click($selector); | ||||
} | } | ||||
/** | /** | ||||
* Assert an error message on the widget | * Assert an error message on the widget | ||||
*/ | */ | ||||
public function assertFormError($browser, int $num, string $msg, bool $focused = false) | public function assertFormError($browser, int $num, string $msg, bool $focused = false) | ||||
{ | { | ||||
$selector = '.input-group:nth-child(' . ($num + 1) . ') input.is-invalid'; | $selector = '.input-group:nth-child(' . ($num + 1) . ') input.is-invalid'; | ||||
Show All 9 Lines |