Skip to content

Commit

Permalink
test: add regression test for instanceof
Browse files Browse the repository at this point in the history
Add regression test for issue #7592.
The issue was fixed in upstream V8 and this test case was
previously added with a manual cherry pick for v6.x.

Related to: #7638 and
#7592.
  • Loading branch information
fhinkel committed Oct 20, 2016
1 parent bb173f9 commit f376ad4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/parallel/test-instanceof.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
'use strict';
require('../common');
const assert = require('assert');


// Regression test for instanceof, see
// https://github.com/nodejs/node/issues/7592
const F = () => {};
F.prototype = {};
assert(Object.create(F.prototype) instanceof F);

0 comments on commit f376ad4

Please sign in to comment.