@@ -235,11 +235,14 @@ Rectangle {
236 function test_unlock_data() {
236 function test_unlock_data() {
238− {tag: "numeric", alphanumeric: false, password: "1234", minPinLength: 4, maxPinLength: 4},
238+ {tag: "numeric", alphanumeric: false, password: "1234", minPinLength: 4, maxPinLength: 4, keyboard: false},
239− {tag: "alphanumeric", alphanumeric: true, password: "password", minPinLength: -1, maxPinLength: -1},
239+ {tag: "alphanumeric", alphanumeric: true, password: "password", minPinLength: -1, maxPinLength: -1, keyboard: false},
240− {tag: "numeric (wrong)", alphanumeric: false, password: "4321", minPinLength: 4, maxPinLength: 4},
240+ {tag: "numeric (wrong)", alphanumeric: false, password: "4321", minPinLength: 4, maxPinLength: 4, keyboard: false},
241− {tag: "alphanumeric (wrong)", alphanumeric: true, password: "drowssap", minPinLength: -1, maxPinLength: -1},
241+ {tag: "alphanumeric (wrong)", alphanumeric: true, password: "drowssap", minPinLength: -1, maxPinLength: -1, keyboard: false},
242− {tag: "flexible length", alphanumeric: false, password: "1234", minPinLength: -1, maxPinLength: -1},
242+ {tag: "flexible length", alphanumeric: false, password: "1234", minPinLength: -1, maxPinLength: -1, keyboard: false},
243+ {tag: "numeric", alphanumeric: false, password: "1234", minPinLength: 4, maxPinLength: 4, keyboard: true},
244+ {tag: "numeric (wrong)", alphanumeric: false, password: "4321", minPinLength: 4, maxPinLength: 4, keyboard: true},
245+ {tag: "flexible length", alphanumeric: false, password: "1234", minPinLength: -1, maxPinLength: -1, keyboard: true}
@@ -259,8 +262,12 @@ Rectangle {
260 for (var i = 0; i < data.password.length; ++i) {
263 for (var i = 0; i < data.password.length; ++i) {
261 var character = data.password.charAt(i)
264 var character = data.password.charAt(i)
265+ if (data.keyboard) {
266+ typeString(character)
262− var button = findChild(lockscreen, "pinPadButton" + character)
268+ var button = findChild(lockscreen, "pinPadButton" + character)
263− mouseClick(button, units.gu(1), units.gu(1))
269+ mouseClick(button, units.gu(1), units.gu(1))
265 var confirmButton = findChild(lockscreen, "confirmButton");
272 var confirmButton = findChild(lockscreen, "confirmButton");
266 mouseClick(confirmButton, units.gu(1), units.gu(1));
273 mouseClick(confirmButton, units.gu(1), units.gu(1));