From cf8e37311670e1b2380966d2dd5e92ffaaaacf23 Mon Sep 17 00:00:00 2001 From: Marcelo Boveto Shima Date: Thu, 4 Mar 2021 21:25:08 -0300 Subject: [PATCH] MockedGenerator should extend Generator. --- lib/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/index.js b/lib/index.js index 738a9ce..f04e551 100644 --- a/lib/index.js +++ b/lib/index.js @@ -152,7 +152,7 @@ YeomanTest.prototype.mockLocalConfig = function (generator, localConfig) { */ YeomanTest.prototype.createMockedGenerator = ( - Generator = require('yeoman-generator') + Generator = class MockedGenerator extends require('yeoman-generator') {} ) => { const generator = sinon.spy(Generator); ['run', 'queueTasks', 'runWithOptions', 'queueOwnTasks'].forEach(