Local file storage (#5763)
Co-authored-by: Tom Moor <tom.moor@gmail.com>
This commit is contained in:
@@ -99,7 +99,7 @@ router.post(
|
||||
|
||||
ctx.body = {
|
||||
data: {
|
||||
uploadUrl: FileStorage.getPublicEndpoint(),
|
||||
uploadUrl: FileStorage.getUploadUrl(),
|
||||
form: {
|
||||
"Cache-Control": "max-age=31557600",
|
||||
"Content-Type": contentType,
|
||||
|
||||
@@ -13,7 +13,8 @@ describe("auth/redirect", () => {
|
||||
}
|
||||
);
|
||||
expect(res.status).toEqual(302);
|
||||
expect(res.headers.get("location").endsWith("/home")).toBeTruthy();
|
||||
expect(res.headers.get("location")).not.toBeNull();
|
||||
expect(res.headers.get("location")!.endsWith("/home")).toBeTruthy();
|
||||
});
|
||||
|
||||
it("should redirect to first collection", async () => {
|
||||
@@ -28,6 +29,7 @@ describe("auth/redirect", () => {
|
||||
}
|
||||
);
|
||||
expect(res.status).toEqual(302);
|
||||
expect(res.headers.get("location").endsWith(collection.url)).toBeTruthy();
|
||||
expect(res.headers.get("location")).not.toBeNull();
|
||||
expect(res.headers.get("location")!.endsWith(collection.url)).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user