test: update tests directory

This commit is contained in:
Ritesh Ghosh
2025-05-12 00:03:39 +05:30
parent a72f469f40
commit 468a6e3ef9
12 changed files with 0 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
import { expect, test } from "vitest";
import { HiAnime } from "aniwatch";
const genreName = "shounen";
const page = 2;
// npx vitest run animeGenre.test.ts
test(`GET /api/v2/hianime/genre/${genreName}?page=${page}`, async () => {
const hianime = new HiAnime.Scraper();
const data = await hianime.getGenreAnime(genreName, page);
expect(data.animes).not.toEqual([]);
expect(data.genres).not.toEqual([]);
expect(data.topAiringAnimes).not.toEqual([]);
});