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

Commit 0858280

Browse files
committed
fix(locators): by.cssContainingText now operates on pre-transformed text
Previously, the implementation depended on the browser. Now, it will always operate on the text before text-transform is applied. Closes #1217
1 parent 12e4101 commit 0858280

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/clientsidescripts.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,7 @@ functions.findByCssContainingText = function(cssSelector, searchText, using) {
489489
var matches = [];
490490
for (var i = 0; i < elements.length; ++i) {
491491
var element = elements[i];
492-
var elementText = element.innerText || element.textContent;
492+
var elementText = element.textContent || element.innerText;
493493
if (elementText.indexOf(searchText) > -1) {
494494
matches.push(element);
495495
}

0 commit comments

Comments
 (0)