mirror of
https://github.com/chaijs/chai
synced 2024-11-15 00:07:11 +00:00
Not check instaceOf if __proto__ is not supported
This commit is contained in:
parent
7683356fff
commit
d0242ee9e5
1 changed files with 5 additions and 1 deletions
|
@ -1026,7 +1026,11 @@ describe('utilities', function () {
|
|||
|
||||
// Ensure that foo returns an Assertion (not a function)
|
||||
expect(expect('x').x()).to.be.an.instanceOf(assertionConstructor);
|
||||
|
||||
var hasProtoSupport = '__proto__' in Object;
|
||||
if (hasProtoSupport) {
|
||||
expect(expect('x').x).to.be.an.instanceOf(assertionConstructor);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue