Skip to content

Commit 3573065

Browse files
heath-freenomenickgros
authored andcommitted
- Fixed snapshots for antd and remove mocking of nanoid for daisyui
1 parent 135d5fb commit 3573065

File tree

7 files changed

+1787
-1801
lines changed

7 files changed

+1787
-1801
lines changed

packages/antd/test/__snapshots__/Array.test.tsx.snap

Lines changed: 435 additions & 435 deletions
Large diffs are not rendered by default.

packages/antd/test/__snapshots__/Form.test.tsx.snap

Lines changed: 315 additions & 315 deletions
Large diffs are not rendered by default.

packages/antd/test/__snapshots__/GridSnap.test.tsx.snap

Lines changed: 686 additions & 686 deletions
Large diffs are not rendered by default.

packages/antd/test/__snapshots__/Object.test.tsx.snap

Lines changed: 350 additions & 350 deletions
Large diffs are not rendered by default.

packages/daisyui/test/helpers/createMocks.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,6 @@ import validator from '@rjsf/validator-ajv8';
55
import Templates from '../../src/templates/Templates';
66
import generateWidgets from '../../src/widgets/Widgets';
77

8-
// Mock any problematic dependencies
9-
// This helps when a dependency like uniqueId uses ESM
10-
jest.mock('lodash/uniqueId', () => ({
11-
nanoid: () => 'test-id-12345',
12-
}));
13-
148
export const mockSchema: RJSFSchema = {
159
type: 'array',
1610
items: {

packages/daisyui/test/setup.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1 @@
1-
// Mock nanoid to avoid ESM import issues and generate unique IDs
2-
jest.mock('nanoid', () => {
3-
let mockCounter = 0;
4-
return {
5-
nanoid: () => `test-id-${mockCounter++}`,
6-
};
7-
});
8-
91
// Set up any other global mocks or configuration needed for tests

packages/mantine/jest.config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
"testEnvironmentOptions": {
77
"browsers": ["chrome", "firefox", "safari"]
88
},
9-
"transformIgnorePatterns": ["/node_modules/(?!nanoid)"]
9+
"transformIgnorePatterns": ["/node_modules/(?!deep-freeze-es6)"]
1010
}

0 commit comments

Comments
 (0)