-
Notifications
You must be signed in to change notification settings - Fork 6
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
to satisfy: Improve diffs and support asserting textContent. #27
to satisfy: Improve diffs and support asserting textContent. #27
Conversation
The Travis failure seems bogus, any idea @Munter? |
Looks like just a temporary glitch. Rerunning it worked |
The changes look great. Thanks! |
to satisfy: Improve diffs and support asserting textContent.
Published in 1.3.0 |
@Munter awesome, this plugin is tremendously useful. It is the first time I'm using it. |
@Munter I was trying to achieve this: https://github.com/One-com/knockout.autocomplete/blob/master/test/knockout.autocomplete.spec.js#L37-L63 and ran into a very weird diff :-) |
Seeing deep structures like that makes me want to enable html syntax in the comparison, like what @bruderstein is doing in https://github.com/bruderstein/unexpected-react-shallow Unfortunately not as easy in actual dom versus virtual dom |
@Munter I don't exactly understand what you mean, the html is syntax highlighted in the diff. |
|
@Munter is it |
That assertion makes sense, it should parse the rhs as html and copy the lhs, trim and remove all empty text nodes and use |
@Munter sorry I completely misunderstood you - you want jsx in you your tests, with highlighting in you editor right? |
Jsx, maybe. Html as a string might also be more readable. Means having to learn less of the specific syntax for the assertion |
Maybe the new strings in es6 would work in combination with an editor extension: expect(node, 'to render as', html`<div class="foo">bar</div>`); |
No description provided.