mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 13:59:16 +01:00
refactor: 🚨 Turn every linter rule on and fix issues (there were a LOT :3)
This commit is contained in:
parent
2e98859153
commit
a1e02d0d78
177 changed files with 1826 additions and 1248 deletions
|
|
@ -36,7 +36,7 @@ describe("MediaBackend", () => {
|
|||
describe("fromBackendType", () => {
|
||||
it("should return a LocalMediaBackend instance for LOCAL backend type", async () => {
|
||||
const backend = await MediaBackend.fromBackendType(
|
||||
MediaBackendType.LOCAL,
|
||||
MediaBackendType.Local,
|
||||
mockConfig,
|
||||
);
|
||||
expect(backend).toBeInstanceOf(LocalMediaBackend);
|
||||
|
|
@ -62,8 +62,8 @@ describe("MediaBackend", () => {
|
|||
it("should throw an error for unknown backend type", () => {
|
||||
expect(
|
||||
// @ts-expect-error This is a test
|
||||
MediaBackend.fromBackendType("unknown", mockConfig),
|
||||
).rejects.toThrow("Unknown backend type: unknown");
|
||||
() => MediaBackend.fromBackendType("unknown", mockConfig),
|
||||
).toThrow("Unknown backend type: unknown");
|
||||
});
|
||||
});
|
||||
|
||||
|
|
@ -228,7 +228,7 @@ describe("LocalMediaBackend", () => {
|
|||
|
||||
it("should initialize with correct type", () => {
|
||||
expect(localMediaBackend.getBackendType()).toEqual(
|
||||
MediaBackendType.LOCAL,
|
||||
MediaBackendType.Local,
|
||||
);
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue