Skip to content

Commit 3dc9f1a

Browse files
committed
fix(e2e): .vs__search is a wrapper now, not the input
development is red on E2E with three failures, all the same error: locator.fill: Element is not an <input>, <textarea>, <select> or [contenteditable] > 181 | await picker.fill(APP_A) > 126 | await picker.fill(name) @nextcloud/vue 9.10 reworked NcSelect -- 'fix(NcSelect): floating label design using NcTextField' (#8570) -- and NcTextField renders a wrapper. Observed on a live 9.11 build rather than inferred: .vs__search -> <div class="input-field vs__search"> parent: div.vs__selected-options inputInside: true It used to BE the <input>; it is now a div that CONTAINS one. Targeting the input inside restores the old meaning and reads correctly against either version. catalog-ratings.spec.ts is fixed too. It was not among the three failures -- its test may not have reached that line -- but it holds the identical selector and would fail the same way. Fixing the instance and leaving the class is how this comes back. Verified: the DOM shape was measured against a seeded launchpad-demo instance on :8605 running a build against 9.11, not read off a changelog.
1 parent d802a5f commit 3dc9f1a

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

tests/e2e/spec-coverage/catalog-ratings.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ async function submitReview(
173173
.getByRole('textbox', { name: /^Title/ })
174174
.first()
175175
.fill(reviewTitle)
176-
const rater = dialog.locator('.vs__search').first()
176+
const rater = dialog.locator('.vs__search input').first()
177177
await rater.click()
178178
await page
179179
.locator('.vs__dropdown-option', { hasText: new RegExp(`^${rating}$`) })

tests/e2e/spec-coverage/suite-wizard.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ async function fillDetails(page: Page): Promise<void> {
121121
/** Attach one seeded module through the real NcSelect multi-picker. */
122122
async function attachApplication(page: Page, name: string): Promise<void> {
123123
const w = wizard(page)
124-
const picker = w.locator('.suite-wizard-step2 .vs__search').first()
124+
const picker = w.locator('.suite-wizard-step2 .vs__search input').first()
125125
await picker.click()
126126
await picker.fill(name)
127127
// The option list is teleported to body by vue-select, so it is queried on
@@ -176,7 +176,7 @@ test('suite wizard: the applications step offers existing modules and no create
176176
// The picker offers a module that genuinely exists in the register — the
177177
// one this run seeded. If the step invented its own options, or fetched
178178
// nothing, this fails.
179-
const picker = w.locator('.suite-wizard-step2 .vs__search').first()
179+
const picker = w.locator('.suite-wizard-step2 .vs__search input').first()
180180
await picker.click()
181181
await picker.fill(APP_A)
182182
await expect(

0 commit comments

Comments
 (0)