mirror of https://github.com/vector-im/riot-web
Update test
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>t3chguy/react18/update
parent
fd49787821
commit
a033d031b5
|
@ -336,22 +336,19 @@ describe("loading:", function () {
|
|||
});
|
||||
});
|
||||
|
||||
it("shows a home page by default if we have no joined rooms", function () {
|
||||
it("shows a home page by default if we have no joined rooms", async () => {
|
||||
localStorage.removeItem("mx_last_room_id");
|
||||
|
||||
loadApp();
|
||||
|
||||
return awaitLoggedIn(matrixChat!)
|
||||
.then(() => {
|
||||
// we are logged in - let the sync complete
|
||||
return expectAndAwaitSync();
|
||||
})
|
||||
.then(() => {
|
||||
// once the sync completes, we should have a home page
|
||||
httpBackend.verifyNoOutstandingExpectation();
|
||||
expect(matrixChat?.container.querySelector(".mx_HomePage")).toBeTruthy();
|
||||
expect(windowLocation?.hash).toEqual("#/home");
|
||||
});
|
||||
await awaitLoggedIn(matrixChat!);
|
||||
// we are logged in - let the sync complete
|
||||
await expectAndAwaitSync();
|
||||
// once the sync completes, we should have a home page
|
||||
httpBackend.verifyNoOutstandingExpectation();
|
||||
await waitFor(() => matrixChat?.container.querySelector(".mx_HomePage"));
|
||||
expect(matrixChat?.container.querySelector(".mx_HomePage")).toBeTruthy();
|
||||
expect(windowLocation?.hash).toEqual("#/home");
|
||||
});
|
||||
|
||||
it("shows a room view if we followed a room link", function () {
|
||||
|
|
Loading…
Reference in New Issue