Skip to content

Add visible_html to assertions#63

Open
idabmat wants to merge 6 commits intoboydm:masterfrom
idabmat:master
Open

Add visible_html to assertions#63
idabmat wants to merge 6 commits intoboydm:masterfrom
idabmat:master

Conversation

@idabmat
Copy link

@idabmat idabmat commented Jul 14, 2022

Thanks @boydm for this library.

I'm aware this has been stable for a while. Just wondering if a change in this direction would be welcome. When asserting against html, dumping the raw body of the response can make it tricky to spot where and why the failure occurred. Also, I'd like to avoid tests to pass if a match was found on some html attribute for example.

The idea would be to provide a way to assert only against the "visible" part of html, using Floki.text/1.

This is a rough spike of the idea. If there is interest in such a change, I'd be happy to polish it as needed and update the docs accordingly.

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.

1 participant