mirror of
https://github.com/brendan-ch/project-inter-server.git
synced 2026-04-17 16:00:32 +00:00
add test setup
This commit is contained in:
@@ -1,9 +1,18 @@
|
|||||||
import { describe, it } from "@jest/globals";
|
import { beforeEach, describe, it } from "@jest/globals";
|
||||||
|
import { NotificationService } from "../../src/services/NotificationService";
|
||||||
|
import { UnoptimizedInMemoryRepository } from "../../src/repositories/UnoptimizedInMemoryRepository";
|
||||||
|
|
||||||
describe("NotificationService", () => {
|
describe("NotificationService", () => {
|
||||||
|
let repository: UnoptimizedInMemoryRepository
|
||||||
|
let notificationService: NotificationService;
|
||||||
|
|
||||||
|
beforeEach(() => {
|
||||||
|
repository = new UnoptimizedInMemoryRepository();
|
||||||
|
notificationService = new NotificationService(repository);
|
||||||
|
})
|
||||||
|
|
||||||
describe("reloadAPNsTokenIfTimePassed", () => {
|
describe("reloadAPNsTokenIfTimePassed", () => {
|
||||||
it("reloads the token if token hasn't been generated yet", async () => {
|
it("reloads the token if token hasn't been generated yet", async () => {
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it("doesn't reload the token if last refreshed time is recent", async () => {
|
it("doesn't reload the token if last refreshed time is recent", async () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user