2024-12-23 16:47:07 +01:00
|
|
|
import { describe, it } from "@jest/globals"
|
2024-12-16 21:25:36 +00:00
|
|
|
|
2024-12-01 20:48:42 +01:00
|
|
|
import { daily } from "@/main.ts"
|
|
|
|
import { ActualImpl } from "@/actual.ts"
|
|
|
|
import { BankStub } from "./stubs/bankStub.ts"
|
|
|
|
|
2024-12-23 16:47:07 +01:00
|
|
|
// TODO testcontainers with Actual?
|
|
|
|
// TODO tests don't stop after completing
|
|
|
|
|
2024-12-01 20:48:42 +01:00
|
|
|
describe("Main logic of the application", () => {
|
|
|
|
it("should import the transactions to Actual Budget", async () => {
|
2024-12-23 16:47:07 +01:00
|
|
|
const actual = await ActualImpl.init()
|
|
|
|
await daily(actual, new BankStub())
|
|
|
|
await actual.shutdown()
|
2024-12-01 20:48:42 +01:00
|
|
|
})
|
|
|
|
})
|