Skip to content

Commit 2c159ad

Browse files
authored
tests: enable tests for generators (#2063)
1 parent 65e6b74 commit 2c159ad

File tree

3 files changed

+4
-9
lines changed

3 files changed

+4
-9
lines changed

packages/generators/__tests__/addon-generator.test.ts

+2-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
jest.setMock('@webpack-cli/utils', {
2-
getPackageManager: jest.fn(),
3-
});
1+
jest.mock('webpack-cli/lib/utils/get-package-manager', () => jest.fn());
42

53
import fs from 'fs';
64
import path from 'path';
@@ -10,8 +8,7 @@ import addonGenerator from '../src/addon-generator';
108

119
const { getPackageManager } = utils;
1210

13-
// TODO: enable after jest release
14-
describe.skip('addon generator', () => {
11+
describe('addon generator', () => {
1512
let gen, installMock, packageMock;
1613
const genName = 'test-addon';
1714
const testAssetsPath = path.join(__dirname, 'test-assets');

packages/generators/__tests__/utils/languageSupport.test.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import language, { LangType, getBabelLoader, getTypescriptLoader } from '../../lib/utils/languageSupport';
22
import { CustomGenerator } from '../../lib/types';
33

4-
// TODO: enable after jest release
5-
describe.skip('languageSupport', () => {
4+
describe('languageSupport', () => {
65
const getMockGenerator = (): CustomGenerator => {
76
const gen = new CustomGenerator(null, null);
87
gen.entryOption = "'./path/to/index.js'";

packages/generators/__tests__/utils/styleSupport.test.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import style, { StylingType } from '../../lib/utils/styleSupport';
22
import { CustomGenerator } from '../../lib/types';
33

4-
// TODO: enable after jest release
5-
describe.skip('styleSupport', () => {
4+
describe('styleSupport', () => {
65
const getMockGenerator = (): CustomGenerator => {
76
const gen = new CustomGenerator(null, null);
87
gen.dependencies = [];

0 commit comments

Comments
 (0)