Skip to content
This repository was archived by the owner on Jul 26, 2023. It is now read-only.

Improves error messages for toHaveText and toContainElement matchers - #281

Open
jwark wants to merge 1 commit into
velesin:masterfrom
jwark:master
Open

Improves error messages for toHaveText and toContainElement matchers#281
jwark wants to merge 1 commit into
velesin:masterfrom
jwark:master

Conversation

@jwark

@jwark jwark commented Feb 29, 2016

Copy link
Copy Markdown

Improves error messages for toHaveText and toContainElement matchers when expectation not met.

E.g.:
expect($('.page-title')).toHaveText('My header');

Expected ({ 0: HTMLNode, length: 1, prevObject: ({ 0: HTMLNode, context: HTMLNode, length: 1 }), context: HTMLNode, selector: '.page-title' }) to have text 'My header'.

Expected element '<h1 class="my-class">My heading</h1>' to have text My header

@uzikilon

Copy link
Copy Markdown

+1

@seansellek

Copy link
Copy Markdown

Any update on this? It's been over a year and this is extremely useful

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants