Conform more of the codebase to strictNullChecks + noImplicitAny (#11179)
This commit is contained in:
parent
7c211b0587
commit
a294ba2ad4
17 changed files with 104 additions and 88 deletions
|
@ -19,6 +19,7 @@ import React from "react";
|
|||
import { fireEvent, render, screen, act } from "@testing-library/react";
|
||||
import userEvent from "@testing-library/user-event";
|
||||
import { mocked } from "jest-mock";
|
||||
import { MatrixError } from "matrix-js-sdk/src/matrix";
|
||||
|
||||
import InteractiveAuthDialog from "../../../../src/components/views/dialogs/InteractiveAuthDialog";
|
||||
import { clearAllModals, flushPromises, getMockClientWithEventEmitter, unmockClientPeg } from "../../../test-utils";
|
||||
|
@ -130,7 +131,7 @@ describe("InteractiveAuthDialog", function () {
|
|||
const successfulResult = { test: 1 };
|
||||
const makeRequest = jest
|
||||
.fn()
|
||||
.mockRejectedValueOnce({ httpStatus: 401, data: { flows: [{ stages: ["m.login.sso"] }] } })
|
||||
.mockRejectedValueOnce(new MatrixError({ data: { flows: [{ stages: ["m.login.sso"] }] } }, 401))
|
||||
.mockResolvedValue(successfulResult);
|
||||
|
||||
mockClient.credentials = { userId: "@user:id" };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue