-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added ability to leave street blank for organisers #922
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The e2e tests give a valid error
Error: locator.fill: Error: strict mode violation: getByLabel('Straat en nummer') resolved to 2 elements:
1) <input type="text" name="address.streetAndNumber" id="organizer-address-streetAndNumber" class="Box__StyledBox-sc-ogeep9-0 dTTsTB form-control"/> aka getByLabel('Straat en nummer', { exact: *** })
2) <input value="" type="checkbox" id="blank_address" name="blank_address" class="Box__StyledBox-sc-ogeep9-0 hiedRv custom-control-input"/> aka getByLabel('Ik wil mijn straat en nummer')
@@ -51,9 +51,10 @@ test('create a place', async ({ baseURL, page }) => { | |||
await page | |||
.getByRole('option', { name: dummyPlace.address.municipality }) | |||
.click(); | |||
await page.getByLabel('Straat en nummer').click(); | |||
await page.getByLabel('Straat en nummer').nth(0).click(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I slightly prefer the first method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you mean? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the issue is maybe placing an actual field inside a field's info slot, which means the label applies to both. Like Playwright is correct that it's iffy. perhaps, I can find a way to work around it so that it's better from a semantics/a11y standpoint
Added
Ticket: https://jira.publiq.be/browse/III-6231