mirror of
https://github.com/prymitive/karma
synced 2026-05-07 03:26:52 +00:00
fix(storybook): add missing fetch mocks
This commit is contained in:
@@ -74,6 +74,27 @@ storiesOf("SilenceModal", module)
|
||||
overwriteRoutes: true
|
||||
}
|
||||
);
|
||||
fetchMock.mock(
|
||||
"begin:/alerts.json?q=tooLong",
|
||||
{
|
||||
body: "error",
|
||||
status: 503
|
||||
},
|
||||
{
|
||||
overwriteRoutes: true
|
||||
}
|
||||
);
|
||||
fetchMock.mock(
|
||||
"begin:/label",
|
||||
{
|
||||
status: 200,
|
||||
body: JSON.stringify([]),
|
||||
headers: { "Content-Type": "application/json" }
|
||||
},
|
||||
{
|
||||
overwriteRoutes: true
|
||||
}
|
||||
);
|
||||
|
||||
return (
|
||||
<React.Fragment>
|
||||
|
||||
Reference in New Issue
Block a user