1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-08-07 21:23:00 +03:00

Better error handling in jump to date (#10405)

- Friendly error messages with details
 - Add a way to submit debug logs for actual errors (non-networking errors)
 - Don't jump someone back to a room they already navigated away from. Fixes bug mentioned in https://github.com/vector-im/element-web/issues/21263#issuecomment-1056809714
This commit is contained in:
Eric Eastwood
2023-03-24 14:39:24 -05:00
committed by GitHub
parent 1af71089dd
commit e5f06df3f7
11 changed files with 424 additions and 83 deletions

View File

@@ -31,6 +31,7 @@ import {
IAuthData,
} from "matrix-js-sdk/src/matrix";
import { clearAllModals } from "../../../../../test-utils";
import SessionManagerTab from "../../../../../../src/components/views/settings/tabs/user/SessionManagerTab";
import MatrixClientContext from "../../../../../../src/contexts/MatrixClientContext";
import {
@@ -161,7 +162,7 @@ describe("<SessionManagerTab />", () => {
await flushPromises();
};
beforeEach(() => {
beforeEach(async () => {
jest.clearAllMocks();
jest.spyOn(logger, "error").mockRestore();
mockClient.getStoredDevice.mockImplementation((_userId, id) => {
@@ -199,7 +200,7 @@ describe("<SessionManagerTab />", () => {
// sometimes a verification modal is in modal state when these tests run
// make sure the coast is clear
Modal.closeCurrentModal("");
await clearAllModals();
});
it("renders spinner while devices load", () => {