Skip to content
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

feat: expect(locator).toHaveAttribute to assert attribute presence #16767

Merged
merged 3 commits into from
Aug 25, 2022

Conversation

aslushnikov
Copy link
Collaborator

This patch changes expect(locator).toHaveAttribute() so that the
value argument can be omitted. When done so, the method will
assert attribute existance.

Fixes #16517

This patch changes `expect(locator).toHaveAttribute()` so that the
`value` argument can be omitted. When done so, the method will
assert attribute existance.

Fixes microsoft#16517
@aslushnikov aslushnikov merged commit 622c73c into microsoft:main Aug 25, 2022
@aslushnikov aslushnikov deleted the optional-to-have-attribute branch August 25, 2022 12:28
rwoll added a commit to rwoll/playwright that referenced this pull request Sep 16, 2022
Revert "docs(python): add missing NotToHaveAttribute overloads (microsoft#17371)"

This reverts commit 2e1ea29.

Revert "docs(release-notes): add 1.26 release notes for language ports (microsoft#17345)"

This reverts commit 4b8a85e.

Revert "test: unflake "should support boolean attribute with options" (microsoft#17024)"

This reverts commit 1dc05bd.

Revert "fix: support toHaveAttribute(name, options) (microsoft#16941)"

This reverts commit f30ac1d.

Revert "feat: expect(locator).toHaveAttribute to assert attribute presence (microsoft#16767)"

This reverts commit 622c73c.
rwoll added a commit that referenced this pull request Sep 16, 2022
Relates #16517.

Revert "docs(python): add missing NotToHaveAttribute overloads (#17371)"

This reverts commit 2e1ea29.

Revert "docs(release-notes): add 1.26 release notes for language ports
(#17345)"

This reverts commit 4b8a85e.

Revert "test: unflake "should support boolean attribute with options"
(#17024)"

This reverts commit 1dc05bd.

Revert "fix: support toHaveAttribute(name, options) (#16941)"

This reverts commit f30ac1d.

Revert "feat: expect(locator).toHaveAttribute to assert attribute
presence (#16767)"

This reverts commit 622c73c.
aslushnikov added a commit that referenced this pull request Sep 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] toHaveAttribute always passes when given a blank value string
2 participants