Use Identity Server v2 API for tests (#24086)
This commit is contained in:
parent
9a55019d65
commit
805c90ade7
1 changed files with 3 additions and 3 deletions
|
@ -224,7 +224,7 @@ describe("loading:", function () {
|
||||||
|
|
||||||
// Pass the liveliness checks
|
// Pass the liveliness checks
|
||||||
httpBackend.when("GET", "/versions").respond(200, { versions: ["r0.4.0"] });
|
httpBackend.when("GET", "/versions").respond(200, { versions: ["r0.4.0"] });
|
||||||
httpBackend.when("GET", "/api/v1").respond(200, {});
|
httpBackend.when("GET", "/_matrix/identity/v2").respond(200, {});
|
||||||
|
|
||||||
return sleep(1)
|
return sleep(1)
|
||||||
.then(async () => {
|
.then(async () => {
|
||||||
|
@ -274,7 +274,7 @@ describe("loading:", function () {
|
||||||
|
|
||||||
// Pass the liveliness checks
|
// Pass the liveliness checks
|
||||||
httpBackend.when("GET", "/versions").respond(200, { versions: ["r0.4.0"] });
|
httpBackend.when("GET", "/versions").respond(200, { versions: ["r0.4.0"] });
|
||||||
httpBackend.when("GET", "/api/v1").respond(200, {});
|
httpBackend.when("GET", "/_matrix/identity/v2").respond(200, {});
|
||||||
|
|
||||||
return awaitLoginComponent(matrixChat)
|
return awaitLoginComponent(matrixChat)
|
||||||
.then(async () => {
|
.then(async () => {
|
||||||
|
@ -286,7 +286,7 @@ describe("loading:", function () {
|
||||||
// the only outstanding request should be a GET /login
|
// the only outstanding request should be a GET /login
|
||||||
// (in particular there should be no /register request for
|
// (in particular there should be no /register request for
|
||||||
// guest registration).
|
// guest registration).
|
||||||
const allowedRequests = ["/_matrix/client/r0/login", "/versions", "/api/v1"];
|
const allowedRequests = ["/_matrix/client/r0/login", "/versions", "/_matrix/identity/v2"];
|
||||||
for (const req of httpBackend.requests) {
|
for (const req of httpBackend.requests) {
|
||||||
if (req.method === "GET" && allowedRequests.find((p) => req.path.endsWith(p))) {
|
if (req.method === "GET" && allowedRequests.find((p) => req.path.endsWith(p))) {
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Reference in a new issue