mirror of
https://github.com/n08i40k/schedule-parser-next.git
synced 2025-12-06 09:47:46 +03:00
Убрана неиспользуемая фича и обновлены тесты.
This commit is contained in:
4289
package-lock.json
generated
4289
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -71,12 +71,12 @@
|
||||
"eslint": "9.18.0",
|
||||
"eslint-plugin-prettier": "5.2.3",
|
||||
"fastify": "^5.2.1",
|
||||
"jest": "^29.7.0",
|
||||
"jest": "^30.0.0-alpha.7",
|
||||
"prettier": "3.4.2",
|
||||
"prisma": "^6.2.1",
|
||||
"source-map-support": "^0.5.21",
|
||||
"supertest": "^7.0.0",
|
||||
"ts-jest": "^29.2.5",
|
||||
"ts-jest": "^29.3.2",
|
||||
"ts-loader": "^9.5.2",
|
||||
"ts-node": "^10.9.2",
|
||||
"tsconfig-paths": "^4.2.0",
|
||||
|
||||
@@ -54,7 +54,7 @@ describe("ScheduleParser", () => {
|
||||
describe("Расписание", () => {
|
||||
beforeEach(async () => {
|
||||
await setLink(
|
||||
"https://politehnikum-eng.ru/2024/poltavskaja_15_s_9_po_13.12-1-.xls",
|
||||
"https://politehnikum-eng.ru/2025/poltavskaja_31_s_14_po_20_04-1_.xls",
|
||||
);
|
||||
});
|
||||
|
||||
@@ -69,7 +69,7 @@ describe("ScheduleParser", () => {
|
||||
);
|
||||
expect(schedule).toBeDefined();
|
||||
|
||||
const group: Group | undefined = schedule.groups.get("ИС-114/23");
|
||||
const group: Group | undefined = schedule.groups.get("ИС-112/24");
|
||||
expect(group).toBeDefined();
|
||||
|
||||
const day = group.days[0];
|
||||
|
||||
@@ -563,11 +563,6 @@ export class ScheduleParser {
|
||||
groups.set(group.name, group);
|
||||
}
|
||||
|
||||
const updatedGroups = ScheduleParser.getUpdatedGroups(
|
||||
this.lastResult?.groups,
|
||||
groups,
|
||||
);
|
||||
|
||||
const teachers = ScheduleParser.convertGroupsToTeachers(groups);
|
||||
|
||||
return (this.lastResult = {
|
||||
@@ -580,11 +575,7 @@ export class ScheduleParser {
|
||||
groups: groups,
|
||||
teachers: teachers,
|
||||
|
||||
updatedGroups:
|
||||
updatedGroups.length === 0
|
||||
? (this.lastResult?.updatedGroups ?? [])
|
||||
: updatedGroups,
|
||||
|
||||
updatedGroups: [],
|
||||
updatedTeachers: [], // TODO: Вернуть эту фичу
|
||||
});
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ describe("BasicXlsDownloader", () => {
|
||||
|
||||
it("Должен вернуть скачанный файл", async () => {
|
||||
await downloader.setDownloadUrl(
|
||||
"https://politehnikum-eng.ru/2024/poltavskaja_15_s_9_po_13.12-1-.xls",
|
||||
"https://politehnikum-eng.ru/2025/poltavskaja_31_s_14_po_20_04-1_.xls",
|
||||
);
|
||||
|
||||
expect(() => {
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
import { Test, TestingModule } from "@nestjs/testing";
|
||||
import { VKIDController } from "./vkid.controller";
|
||||
|
||||
describe("VkidController", () => {
|
||||
let controller: VKIDController;
|
||||
|
||||
beforeEach(async () => {
|
||||
const module: TestingModule = await Test.createTestingModule({
|
||||
controllers: [VKIDController],
|
||||
}).compile();
|
||||
|
||||
controller = module.get<VKIDController>(VKIDController);
|
||||
});
|
||||
|
||||
it("should be defined", () => {
|
||||
expect(controller).toBeDefined();
|
||||
});
|
||||
});
|
||||
@@ -1,3 +1,4 @@
|
||||
|
||||
import {
|
||||
Body,
|
||||
Controller,
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
import { Test, TestingModule } from "@nestjs/testing";
|
||||
import { VKIDService } from "./vkid.service";
|
||||
|
||||
describe("VkidService", () => {
|
||||
let service: VKIDService;
|
||||
|
||||
beforeEach(async () => {
|
||||
const module: TestingModule = await Test.createTestingModule({
|
||||
providers: [VKIDService],
|
||||
}).compile();
|
||||
|
||||
service = module.get<VKIDService>(VKIDService);
|
||||
});
|
||||
|
||||
it("should be defined", () => {
|
||||
expect(service).toBeDefined();
|
||||
});
|
||||
});
|
||||
@@ -1,6 +1,5 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"builder": "swc",
|
||||
"module": "commonjs",
|
||||
"declaration": true,
|
||||
"removeComments": true,
|
||||
|
||||
Reference in New Issue
Block a user