Skip to content

Commit a8e9756

Browse files
committed
add 3 levels of proto to Feature.prototype
1 parent dc2f95d commit a8e9756

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

index.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,13 @@ function stubService(service) {
4646
var client = new Original();
4747

4848
function FakeService(config) { Object.assign(this, new Original(config)); }
49-
FakeService.prototype = Object.assign({}, client.__proto__);
49+
FakeService.prototype = Object.assign(
50+
{},
51+
client.__proto__.__proto__.__proto__,
52+
client.__proto__.__proto__,
53+
client.__proto__
54+
);
55+
5056

5157
var spy = sinon.spy(FakeService);
5258
spy.restore = function() { setService(service, Original); };

0 commit comments

Comments
 (0)