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

.attr matcher unexpected changes subject #65

Open
SevenOutman opened this issue Mar 27, 2023 · 1 comment
Open

.attr matcher unexpected changes subject #65

SevenOutman opened this issue Mar 27, 2023 · 1 comment

Comments

@SevenOutman
Copy link
Contributor

The following assertion with Chai .and chain should work

expect(container.firstChild)
  .to.have.attr('role', 'menubar')
  .and.to.have.attr('aria-orientation', 'vertical');

But it throws

TypeError: el.getAttribute is not a function
@nathanboktae
Copy link
Owner

Yes that is odd. Changing the subject to the attribute isn't interesting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants