-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
135 additions
and
178 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
import { DefaultParamWithSchoolParam } from '.' | ||
import { DefaultParam } from '.' | ||
|
||
export interface SchulAflcoinfoParam extends DefaultParamWithSchoolParam { | ||
export interface SchulAflcoinfoParam extends DefaultParam { | ||
/** 시도교육청코드 */ | ||
readonly ATPT_OFCDC_SC_CODE: string | ||
/** 표준학교코드 */ | ||
readonly SD_SCHUL_CODE?: string | ||
/** 주야과정명 */ | ||
readonly DGHT_CRSE_SC_NM?: string | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,20 @@ | ||
import type { AcaInsTiInfoResponse } from '../src' | ||
import { AE, AN } from './constants' | ||
import { AE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
} | ||
|
||
describe('AcaInsTiInfo', () => { | ||
it('should return AcaInsTiInfoResponse[]', async () => { | ||
const data = await neis.getAcademy({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
}) | ||
const data = await neis.getAcademy(params) | ||
|
||
expect(data).toMatchObject<AcaInsTiInfoResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return AcaInsTiInfoResponse', async () => { | ||
const data = await neis.getAcademyOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
ACA_ASNUM: AN, | ||
}) | ||
const data = await neis.getAcademyOne(params) | ||
|
||
expect(data).toMatchObject<AcaInsTiInfoResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,21 @@ | ||
import type { ClassInfoResponse } from '../src' | ||
import { AE, SE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
} | ||
|
||
describe('ClassInfo', () => { | ||
it('should return ClassInfoResponse[]', async () => { | ||
const data = await neis.getClass({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getClass(params) | ||
|
||
expect(data).toMatchObject<ClassInfoResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return ClassInfoResponse', async () => { | ||
const data = await neis.getClassOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
GRADE: '1', | ||
}) | ||
const data = await neis.getClassOne(params) | ||
|
||
expect(data).toMatchObject<ClassInfoResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,21 @@ | ||
import type { ElsTimetableResponse } from '../src' | ||
import { AE, ELS, YMD } from './constants' | ||
import { AE, ELS } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: ELS, | ||
} | ||
|
||
describe('ElsTimetable', () => { | ||
it('should return ElsTimetableResponse[]', async () => { | ||
const data = await neis.getElsTimetable({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: ELS, | ||
ALL_TI_YMD: YMD, | ||
}) | ||
const data = await neis.getElsTimetable(params) | ||
|
||
expect(data).toMatchObject<ElsTimetableResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return ElsTimetableResponse', async () => { | ||
const data = await neis.getElsTimetableOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: ELS, | ||
ALL_TI_YMD: YMD, | ||
GRADE: '1', | ||
CLASS_NM: '1', | ||
PERIO: '1', | ||
}) | ||
const data = await neis.getElsTimetableOne(params) | ||
|
||
expect(data).toMatchObject<ElsTimetableResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,21 @@ | ||
import type { HisTimetableResponse } from '../src' | ||
import { AE, HIS, YMD } from './constants' | ||
import { AE, HIS } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: HIS, | ||
} | ||
|
||
describe('HisTimetable', () => { | ||
it('should return HisTimetableResponse[]', async () => { | ||
const data = await neis.getHisTimetable({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: HIS, | ||
ALL_TI_YMD: YMD, | ||
}) | ||
const data = await neis.getHisTimetable(params) | ||
|
||
expect(data).toMatchObject<HisTimetableResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return HisTimetableResponse', async () => { | ||
const data = await neis.getHisTimetableOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: HIS, | ||
ALL_TI_YMD: YMD, | ||
GRADE: '1', | ||
CLASS_NM: '1', | ||
}) | ||
const data = await neis.getHisTimetableOne(params) | ||
|
||
expect(data).toMatchObject<HisTimetableResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,21 @@ | ||
import type { MealServiceDietInfoResponse } from '../src' | ||
import { AE, SE, YMD } from './constants' | ||
import { AE, SE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
} | ||
|
||
describe('MealServiceDietInfo', () => { | ||
it('should return MealServiceDietInfoResponse[]', async () => { | ||
const data = await neis.getMeal({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getMeal(params) | ||
|
||
expect(data).toMatchObject<MealServiceDietInfoResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return MealServiceDietInfoResponse', async () => { | ||
const data = await neis.getMealOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
MLSV_YMD: YMD, | ||
}) | ||
const data = await neis.getMealOne(params) | ||
|
||
expect(data).toMatchObject<MealServiceDietInfoResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,21 @@ | ||
import type { MisTimetableResponse } from '../src' | ||
import { AE, MIS, YMD } from './constants' | ||
import { AE, MIS } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: MIS, | ||
} | ||
|
||
describe('MisTimetable', () => { | ||
it('should return MisTimetableResponse[]', async () => { | ||
const data = await neis.getMisTimetable({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: MIS, | ||
ALL_TI_YMD: YMD, | ||
}) | ||
const data = await neis.getMisTimetable(params) | ||
|
||
expect(data).toMatchObject<MisTimetableResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return MisTimetableResponse', async () => { | ||
const data = await neis.getMisTimetableOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: MIS, | ||
ALL_TI_YMD: YMD, | ||
GRADE: '1', | ||
CLASS_NM: '1', | ||
PERIO: '1', | ||
}) | ||
const data = await neis.getMisTimetableOne(params) | ||
|
||
expect(data).toMatchObject<MisTimetableResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,22 @@ | ||
import type { SchoolInfoResponse } from '../src' | ||
import { AE, SE } from './constants' | ||
import { AE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
} | ||
|
||
describe('SchoolInfo', () => { | ||
it('should return SchoolInfoResponse[]', async () => { | ||
const data = await neis.getSchool({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
}) | ||
const data = await neis.getSchool(params) | ||
|
||
expect(data).toMatchObject<SchoolInfoResponse[]>(data) | ||
data.forEach((school) => { | ||
expect(school) | ||
}) | ||
}) | ||
|
||
it('should return SchoolInfoResponse', async () => { | ||
const data = await neis.getSchoolOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getSchoolOne(params) | ||
|
||
expect(data).toMatchObject<SchoolInfoResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,20 @@ | ||
import type { SchoolMajorinfoResponse } from '../src' | ||
import { AE, SE } from './constants' | ||
import { AE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
} | ||
|
||
describe('SchoolMajorinfo', () => { | ||
it('should return SchoolMajorinfoResponse[]', async () => { | ||
const data = await neis.getMajor({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getMajor(params) | ||
|
||
expect(data).toMatchObject<SchoolMajorinfoResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return SchoolMajorinfoResponse', async () => { | ||
const data = await neis.getMajorOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getMajorOne(params) | ||
|
||
expect(data).toMatchObject<SchoolMajorinfoResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,21 @@ | ||
import type { SchoolScheduleResponse } from '../src' | ||
import { AE, SE, YMD } from './constants' | ||
import { AE, SE } from './constants' | ||
import { neis } from './utils' | ||
|
||
const params = { | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
} | ||
|
||
describe('SchoolSchedule', () => { | ||
it('should return SchoolScheduleResponse[]', async () => { | ||
const data = await neis.getSchedule({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
}) | ||
const data = await neis.getSchedule(params) | ||
|
||
expect(data).toMatchObject<SchoolScheduleResponse[]>(data) | ||
expect(data) | ||
}) | ||
|
||
it('should return SchoolScheduleResponse', async () => { | ||
const data = await neis.getScheduleOne({ | ||
ATPT_OFCDC_SC_CODE: AE, | ||
SD_SCHUL_CODE: SE, | ||
AA_YMD: YMD, | ||
}) | ||
const data = await neis.getScheduleOne(params) | ||
|
||
expect(data).toMatchObject<SchoolScheduleResponse>(data) | ||
expect(data) | ||
}) | ||
}) |
Oops, something went wrong.