From 474b345988d39c96db0ad03f1e7cfa7b969b64f2 Mon Sep 17 00:00:00 2001 From: Quincy Morgan <2046746+quincylvania@users.noreply.github.com> Date: Tue, 13 Oct 2020 16:03:00 -0400 Subject: [PATCH] Send keydown events when testing uiCombobox --- test/spec/ui/combobox.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/spec/ui/combobox.js b/test/spec/ui/combobox.js index f71ba371b..6362018e8 100644 --- a/test/spec/ui/combobox.js +++ b/test/spec/ui/combobox.js @@ -15,6 +15,8 @@ describe('uiCombobox', function() { var start = input.property('selectionStart'); var finis = input.property('selectionEnd'); + happen.keydown(input.node(), {keyCode: keyCode}); + switch (key) { case '⇥': break; @@ -86,7 +88,7 @@ describe('uiCombobox', function() { input.call(combobox.data(data)); focusTypeahead(input); simulateKeypress('↓'); - expect(d3.select('.ideditor > div.combobox').nodes().length).to.equal(1); + expect(d3.selectAll('.ideditor > div.combobox').size()).to.equal(1); }); it('filters entries to those matching the value', function() {