aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorRichard Gibson <richard.gibson@gmail.com>2017-07-19 11:45:03 -0400
committerRichard Gibson <richard.gibson@gmail.com>2017-07-19 11:45:03 -0400
commit928c580a1a5fb328604ee94e33f440a326754ae1 (patch)
tree1b948fe9a9f7775ce4f0ac7a24ad493c58174ea6 /test/unit
parent03db56a7e3250ee4a6271ac1b0c2c4053d2999c9 (diff)
downloadjquery-928c580a1a5fb328604ee94e33f440a326754ae1.tar.gz
jquery-928c580a1a5fb328604ee94e33f440a326754ae1.zip
Tests: Reduce the abort timeout for simple focus testing
Ref gh-3732
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/event.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/test/unit/event.js b/test/unit/event.js
index 8a8a5589e..811922cb4 100644
--- a/test/unit/event.js
+++ b/test/unit/event.js
@@ -2810,13 +2810,9 @@ QUnit.test( "preventDefault() on focusin does not throw exception", function( as
done();
done = null;
} );
-
- // This test can be unreliable in CI... try two methods to prompt a focusin event
- // and set an abort timeout
input.trigger( "focus" );
- try {
- input[ 0 ].focus();
- } catch ( e ) {}
+
+ // DOM focus is unreliable in TestSwarm CI; set an abort timeout
setTimeout( function() {
if ( !done ) {
return;
@@ -2824,7 +2820,7 @@ QUnit.test( "preventDefault() on focusin does not throw exception", function( as
assert.ok( true, "Did not intercept focusin" );
done();
done = null;
- }, QUnit.config.testTimeout / 2 || 1000 );
+ }, QUnit.config.testTimeout / 4 || 1000 );
} );
QUnit.test( "Donor event interference", function( assert ) {