@modern-js/generator-cases 1.0.0-rc.2 → 1.0.0-rc.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +249 -0
- package/README.md +21 -20
- package/dist/js/modern/index.js +139 -1
- package/dist/js/node/index.js +160 -2
- package/dist/js/treeshaking/index.js +157 -1
- package/dist/types/index.d.ts +12 -2
- package/package.json +26 -13
- package/src/index.ts +164 -0
- package/tests/__snapshots__/index.test.ts.snap +1310 -0
- package/tests/index.test.ts +20 -1
package/tests/index.test.ts
CHANGED
|
@@ -1,4 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
getMWACases,
|
|
3
|
+
getModuleCases,
|
|
4
|
+
getMonorepoCases,
|
|
5
|
+
getMWANewCases,
|
|
6
|
+
getModuleNewCases,
|
|
7
|
+
getMonorepoNewCases,
|
|
8
|
+
} from '@/index';
|
|
2
9
|
|
|
3
10
|
describe('test generator cases', () => {
|
|
4
11
|
test('test getMWACases', async () => {
|
|
@@ -13,4 +20,16 @@ describe('test generator cases', () => {
|
|
|
13
20
|
const monorepoCases = await getMonorepoCases();
|
|
14
21
|
expect(monorepoCases).toMatchSnapshot();
|
|
15
22
|
});
|
|
23
|
+
test('test getMWANewCases', async () => {
|
|
24
|
+
const mwaNewCases = await getMWANewCases();
|
|
25
|
+
expect(mwaNewCases.length).toBe(22);
|
|
26
|
+
});
|
|
27
|
+
test('test getModuleNewCases', async () => {
|
|
28
|
+
const moduleNewCases = await getModuleNewCases();
|
|
29
|
+
expect(moduleNewCases).toMatchSnapshot();
|
|
30
|
+
});
|
|
31
|
+
test('test getMonorepoNewCases', async () => {
|
|
32
|
+
const monorepoNewCases = await getMonorepoNewCases();
|
|
33
|
+
expect(monorepoNewCases).toMatchSnapshot();
|
|
34
|
+
});
|
|
16
35
|
});
|