File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
public/docs/_examples/user-input Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -54,17 +54,15 @@ describe('User Input Tests', function () {
5454 } ) ;
5555 } ) ;
5656
57- it ( 'should be able to filter key events' , function ( ) {
57+ it ( 'should be able to filter key events' , async ( ) => {
5858 let mainEle = element ( by . css ( 'key-up3' ) ) ;
5959 let inputEle = mainEle . element ( by . css ( 'input' ) ) ;
6060 let outputTextEle = mainEle . element ( by . css ( 'p' ) ) ;
6161 expect ( outputTextEle . getText ( ) ) . toEqual ( '' ) ;
62- return sendKeys ( inputEle , 'abc' ) . then ( function ( ) {
63- expect ( outputTextEle . getText ( ) ) . toEqual ( '' , 'should be blank - have not sent enter yet' ) ;
64- return sendKeys ( inputEle , protractor . Key . ENTER ) ;
65- } ) . then ( function ( ) {
66- expect ( outputTextEle . getText ( ) ) . toEqual ( 'abc' ) ;
67- } ) ;
62+ await sendKeys ( inputEle , 'abc' ) ;
63+ expect ( outputTextEle . getText ( ) ) . toEqual ( '' , 'should be blank - have not sent enter yet' ) ;
64+ await sendKeys ( inputEle , protractor . Key . ENTER ) ;
65+ expect ( outputTextEle . getText ( ) ) . toEqual ( 'abc' ) ;
6866 } ) ;
6967
7068 it ( 'should be able to filter blur events' , function ( ) {
You can’t perform that action at this time.
0 commit comments