Lines Matching refs:constructor
24 description('This test makes sure that instance of behaves correctly when the value, constructor, or its prototype are immediates.');
31 function testSet(constructor, testMethod)
33 testMethod["1"]("(1 instanceof " + constructor + ")");
34 testMethod["{}"]("({} instanceof " + constructor + ")");
35 testMethod["obj"]("(obj instanceof " + constructor + ")");
38 // Test set 1, test passing the integer 1 as the constructor to be tested for.
39 // The constructor being an object is the first thing tested, so these should all throw.
42 // Test set 2, test passing an empty object ({}) as the constructor to be tested for.
43 // As well as being an object, the constructor must implement 'HasInstance' (i.e. be a function), so these should all throw too.
46 // Test set 3, test passing Constructor as the constructor to be tested for.
50 // Test set 4, test passing Constructor as the constructor to be tested for - with Constructor.prototype set to the integer 1.
55 // Test set 5, test passing Constructor as the constructor to be tested for - with Constructor.prototype set to an empty object ({}).
60 // Test set 6, test passing Constructor as the constructor to be tested for - with Constructor.prototype set to null.