Skip to content
This repository has been archived by the owner on May 4, 2023. It is now read-only.

Commit

Permalink
fix(storybook): add missing validateResetToken mock
Browse files Browse the repository at this point in the history
  • Loading branch information
virtuoushub committed Jul 19, 2022
1 parent 6df4696 commit 63457b4
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 1 deletion.
22 changes: 22 additions & 0 deletions .yarn/patches/@redwoodjs-testing-npm-2.1.0-08cd0c4f7e.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/dist/web/MockProviders.js b/dist/web/MockProviders.js
index fcaa1bd8e40b00ac9311fbb60b07bfb3506e9b15..818d2951e333e3a1d5b6199ae56b5d416e489566 100644
--- a/dist/web/MockProviders.js
+++ b/dist/web/MockProviders.js
@@ -61,13 +61,14 @@ const mockAuthClient = {
logout: () => {},
signup: () => {},
getToken: () => {
- return 'token';
+ return "token";
},
getUserMetadata: () => {
return _mockRequests.mockedUserMeta.currentUser;
},
- client: 'Custom',
- type: 'custom'
+ validateResetToken: () => {},
+ client: "Custom",
+ type: "custom",
};
exports.mockAuthClient = mockAuthClient;

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
"@storybook/addon-a11y": "6.5.9",
"@storybook/builder-webpack5": "6.5.9",
"@storybook/manager-webpack5": "6.5.9",
"@storybook/react": "6.5.9"
"@storybook/react": "6.5.9",
"@redwoodjs/testing@2.1.0": "patch:@redwoodjs/testing@npm:2.1.0#.yarn/patches/@redwoodjs-testing-npm-2.1.0-08cd0c4f7e.patch"
},
"packageManager": "yarn@3.2.1"
}
39 changes: 39 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4354,6 +4354,45 @@ __metadata:
languageName: node
linkType: hard

"@redwoodjs/testing@patch:@redwoodjs/testing@npm:2.1.0#.yarn/patches/@redwoodjs-testing-npm-2.1.0-08cd0c4f7e.patch::locator=root-workspace-0b6124%40workspace%3A.":
version: 2.1.0
resolution: "@redwoodjs/testing@patch:@redwoodjs/testing@npm%3A2.1.0#.yarn/patches/@redwoodjs-testing-npm-2.1.0-08cd0c4f7e.patch::version=2.1.0&hash=561279&locator=root-workspace-0b6124%40workspace%3A."
dependencies:
"@babel/runtime-corejs3": 7.16.7
"@redwoodjs/auth": 2.1.0
"@redwoodjs/graphql-server": 2.1.0
"@redwoodjs/internal": 2.1.0
"@redwoodjs/router": 2.1.0
"@redwoodjs/web": 2.1.0
"@storybook/addon-a11y": 6.5.9
"@storybook/addon-docs": 6.5.9
"@storybook/addon-essentials": 6.5.9
"@storybook/builder-webpack5": 6.5.9
"@storybook/manager-webpack5": 6.5.9
"@storybook/react": 6.5.9
"@testing-library/jest-dom": 5.16.4
"@testing-library/react": 12.1.5
"@testing-library/react-hooks": 8.0.0
"@testing-library/user-event": 14.2.0
"@types/aws-lambda": 8.10.97
"@types/babel-core": 6.25.7
"@types/jest": 27.5.2
"@types/node": 16.11.38
"@types/react": 17.0.47
"@types/react-dom": 17.0.17
"@types/webpack": 5.28.0
babel-jest: 27.5.1
babel-plugin-inline-react-svg: 2.0.1
core-js: 3.23.3
jest: 27.5.1
jest-watch-typeahead: 1.1.0
msw: 0.40.2
ts-toolbelt: 9.6.0
whatwg-fetch: 3.6.2
checksum: 9d5333cc1ef7daee399c569d8e0c189a7eb7d58ff24cf70a4a1c03b2e3664c3d85fab932c8db459861090ac06068b4209989121d9481ecb69f363857b7e4a56c
languageName: node
linkType: hard

"@redwoodjs/web@npm:2.1.0":
version: 2.1.0
resolution: "@redwoodjs/web@npm:2.1.0"
Expand Down

0 comments on commit 63457b4

Please sign in to comment.