work on notes api

This commit is contained in:
dd060606
2024-11-18 11:51:00 +01:00
parent 39f9529177
commit 23449c26d2
3 changed files with 71 additions and 2 deletions

16
tests/NotesApi.test.ts Normal file
View File

@@ -0,0 +1,16 @@
import { login } from "../src/api/Session";
describe("NotesApi", () => {
it("should receive notes", async () => {
const username = process.env.TEST_USERNAME;
const password = process.env.TEST_PASSWORD;
if (!username || !password) {
throw new Error(
"TEST_USERNAME or TEST_PASSWORD is not set in environment variables.",
);
}
const session = await login(username, password);
const schedule = await session.getNotesApi().fetchNotes();
expect(schedule).not.toBeDefined();
});
});