Skip to content

Commit

Permalink
fix: test
Browse files Browse the repository at this point in the history
  • Loading branch information
caohuilin committed Nov 5, 2024
1 parent ad194cd commit a9ae416
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 70 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,59 +34,3 @@ exports[`test generator cases test getMWACases 1`] = `
},
]
`;

exports[`test generator cases test getModuleCases 1`] = `
[
{
"language": "js",
"packageManager": "yarn",
"solution": "module",
},
{
"language": "js",
"packageManager": "npm",
"solution": "module",
},
{
"language": "ts",
"packageManager": "yarn",
"solution": "module",
},
{
"language": "ts",
"packageManager": "pnpm",
"solution": "module",
},
{
"language": "js",
"packageManager": "pnpm",
"solution": "module",
},
{
"language": "ts",
"packageManager": "npm",
"solution": "module",
},
]
`;

exports[`test generator cases test getModuleNewCases 1`] = `
[
{
"actionType": "function",
"function": "tailwindcss",
},
{
"actionType": "function",
"function": "storybookV7",
},
{
"actionType": "function",
"function": "runtimeApi",
},
{
"actionType": "function",
"function": "module_doc",
},
]
`;
15 changes: 1 addition & 14 deletions packages/generator/generator-cases/tests/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,12 @@
import {
getMWACases,
getMWANewCases,
getModuleCases,
getModuleNewCases,
} from '../src';
import { getMWACases, getMWANewCases } from '../src';

describe('test generator cases', () => {
test('test getMWACases', async () => {
const mwaCases = getMWACases();
expect(mwaCases).toMatchSnapshot();
});
test('test getModuleCases', async () => {
const moduleCases = getModuleCases();
expect(moduleCases).toMatchSnapshot();
});
test('test getMWANewCases', async () => {
const mwaNewCases = getMWANewCases();
expect(mwaNewCases.length).toBe(11);
});
test('test getModuleNewCases', async () => {
const moduleNewCases = getModuleNewCases();
expect(moduleNewCases).toMatchSnapshot();
});
});

0 comments on commit a9ae416

Please sign in to comment.