Skip to content

Commit

Permalink
Tests: Skip Map and Set cases for QUnit.objectType() on IE 11
Browse files Browse the repository at this point in the history
IE 11 has a non-compliant implementation. For now, treat this
as if it didn't implement these at all.
  • Loading branch information
Krinkle committed Aug 16, 2020
1 parent 80ee531 commit 077e789
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/main/utilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,13 @@ if ( typeof Symbol === "function" ) {
validateObjectType( Symbol( "HI!" ), "symbol" );
}

if ( typeof Map === "function" ) {
// Support IE 11: Skip on IE11's non-compliant implementation
if ( typeof Map === "function" && ( new Map ).toString() !== "[object Object]" ) {
validateObjectType( new Map( ), "map" );
}

if ( typeof Set === "function" ) {
// Support IE 11: Skip on IE11's non-compliant implementation
if ( typeof Set === "function" && ( new Set ).toString() !== "[object Object]" ) {
validateObjectType( new Set( ), "set" );
}

Expand Down

0 comments on commit 077e789

Please sign in to comment.