summaryrefslogtreecommitdiff
path: root/packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts
diff options
context:
space:
mode:
authorzyoshoka <107108195+zyoshoka@users.noreply.github.com>2024-02-08 13:28:49 +0900
committerGitHub <noreply@github.com>2024-02-08 13:28:49 +0900
commit5299d17060d72f1a81edffccedff2f1c78a9c520 (patch)
tree68ab9fc17a2c0336d06459d75a7625570c55712c /packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts
parentFix: Summaly proxy利用時にプレイヤーが動作しないことがあ... (diff)
downloadsharkey-5299d17060d72f1a81edffccedff2f1c78a9c520.tar.gz
sharkey-5299d17060d72f1a81edffccedff2f1c78a9c520.tar.bz2
sharkey-5299d17060d72f1a81edffccedff2f1c78a9c520.zip
test(frontend): migrate MSW in Storybook to v2 (#13195)
Diffstat (limited to 'packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts')
-rw-r--r--packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts14
1 files changed, 7 insertions, 7 deletions
diff --git a/packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts b/packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts
index 5182db12b2..7177d256e1 100644
--- a/packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts
+++ b/packages/frontend/src/components/MkUserSetupDialog.stories.impl.ts
@@ -5,7 +5,7 @@
/* eslint-disable @typescript-eslint/explicit-function-return-type */
import { StoryObj } from '@storybook/vue3';
-import { rest } from 'msw';
+import { HttpResponse, http } from 'msw';
import { commonHandlers } from '../../.storybook/mocks.js';
import { userDetailed } from '../../.storybook/fakes.js';
import MkUserSetupDialog from './MkUserSetupDialog.vue';
@@ -38,17 +38,17 @@ export const Default = {
msw: {
handlers: [
...commonHandlers,
- rest.post('/api/users', (req, res, ctx) => {
- return res(ctx.json([
+ http.post('/api/users', () => {
+ return HttpResponse.json([
userDetailed('44'),
userDetailed('49'),
- ]));
+ ]);
}),
- rest.post('/api/pinned-users', (req, res, ctx) => {
- return res(ctx.json([
+ http.post('/api/pinned-users', () => {
+ return HttpResponse.json([
userDetailed('44'),
userDetailed('49'),
- ]));
+ ]);
}),
],
},