Fix more tests 2 (#18293)
## Summary - Migrate more hand-written test mocks to auto-generated data from a real Twenty instance - Add generators for views, billing plans, API keys; extend record generator for workspace members, favorites, connected accounts, calendar events - Remove 9 hand-written mock files replaced by generated equivalents - Update 16 test/story files to use generated data - Fix WorkflowEditActionEmailBase story assertion to match configured recipient email ## Test plan - [x] Lint, typecheck, unit tests pass - [ ] Storybook tests pass in CI
This commit is contained in:
+2
-2
@@ -13,7 +13,7 @@ import { GET_CURRENT_USER } from '@/users/graphql/queries/getCurrentUser';
|
||||
import { FIND_ALL_CORE_VIEWS } from '@/views/graphql/queries/findAllCoreViews';
|
||||
import { getJestMetadataAndApolloMocksWrapper } from '~/testing/jest/getJestMetadataAndApolloMocksWrapper';
|
||||
import { mockedUserData } from '~/testing/mock-data/users';
|
||||
import { mockedCoreViewsData } from '~/testing/mock-data/views';
|
||||
import { mockedCoreViews } from '~/testing/mock-data/generated/metadata/views/mock-views-data';
|
||||
import {
|
||||
query as findManyObjectMetadataItemsQuery,
|
||||
responseData as findManyObjectMetadataItemsResponseData,
|
||||
@@ -49,7 +49,7 @@ const mocks = [
|
||||
},
|
||||
result: jest.fn(() => ({
|
||||
data: {
|
||||
getCoreViews: mockedCoreViewsData,
|
||||
getCoreViews: mockedCoreViews,
|
||||
},
|
||||
})),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user