Last active
February 21, 2018 16:18
-
-
Save dasDaniel/51e5327651b20a811a0aa3866ca86ff6 to your computer and use it in GitHub Desktop.
Testcafe does not trim values, and IE/Edge seems to keep the whitespace. This solution trims in-line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
<div class="el-with-whitespace> | |
No spaces at the end | |
</div> | |
*/ | |
await t.expect(await Selector('.el-with-whitespace').innerText.then(v => v.trim())).eql('No spaces at the end') | |
// it requires the `await t` otherwise the element doesn't check the updated value |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment