Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 2fbd9d3

Browse files
committed
Merge pull request #10922 from adobe/pflynn/quickopen-unittest-fix
Fix failing QuickOpen unit tests.
2 parents 9dfbebe + 053f7c9 commit 2fbd9d3

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

src/widgets/ModalBar.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ define(function (require, exports, module) {
229229
};
230230

231231
/**
232-
* If autoClose is set, handles the RETURN/ESC keys in the input field.
232+
* If autoClose is set, close the bar when Escape is pressed
233233
*/
234234
ModalBar.prototype._handleKeydown = function (e) {
235235
if (e.keyCode === KeyEvent.DOM_VK_ESCAPE) {

test/spec/QuickOpen-test.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ define(function (require, exports, module) {
8080

8181
testWindow.setTimeout(function () {
8282
getSearchField().val(str);
83+
getSearchField().trigger("input");
8384
}, timeoutLength);
8485
}
8586

@@ -88,7 +89,7 @@ define(function (require, exports, module) {
8889

8990
// Using keyup here because of inside knowledge of how the events are processed
9091
// on the QuickOpen input.
91-
SpecRunnerUtils.simulateKeyEvent(KeyEvent.DOM_VK_RETURN, "keyup", getSearchField()[0]);
92+
SpecRunnerUtils.simulateKeyEvent(KeyEvent.DOM_VK_RETURN, "keydown", getSearchField()[0]);
9293
}
9394

9495
/**

0 commit comments

Comments
 (0)