From 38f4e6cf470481c8704cb559e47e9497ad88ada7 Mon Sep 17 00:00:00 2001 From: Jonathan Lipps Date: Thu, 21 Feb 2013 17:04:39 -0800 Subject: [PATCH] make xpath contains search case insensitive --- app/uiauto/lib/mechanic.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/uiauto/lib/mechanic.js b/app/uiauto/lib/mechanic.js index 90cbf4a0..26ff6908 100644 --- a/app/uiauto/lib/mechanic.js +++ b/app/uiauto/lib/mechanic.js @@ -268,6 +268,9 @@ var mechanic = (function() { if (elKey === null) { return null; } + // make this a case insensitive search + elKey = elKey.toString().toLowerCase(); + val = val.toString().toLowerCase(); if (elKey.indexOf(val) !== -1) { return el;