Skip to content

Commit c0eb913

Browse files
committed
♻️ Refactoring (#1524)
1 parent 671a15b commit c0eb913

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

src/test/lib/utils/test_cases/contest_name_and_task_index.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -263,16 +263,15 @@ const TTPC_TASK_PATTERNS: TtpcTaskPatterns = {
263263
'2023': ['A', 'B', 'C', 'N', 'O', 'P'],
264264
};
265265

266+
const TTPC_YEARS = [2015, 2019, 2022, 2023];
266267
const TTPC_TEST_DATA: UniversityContestsTestData = Object.fromEntries(
267-
Array.from({ length: 9 }, (_, i) => 2015 + i)
268-
.filter((year) => year === 2015 || year === 2019 || year >= 2022)
269-
.map((year) => [
270-
`ttpc${year}`,
271-
{
272-
contestId: `ttpc${year}`,
273-
tasks: TTPC_TASK_PATTERNS[year.toString() as keyof TtpcTaskPatterns],
274-
},
275-
]),
268+
TTPC_YEARS.map((year) => [
269+
`ttpc${year}`,
270+
{
271+
contestId: `ttpc${year}`,
272+
tasks: TTPC_TASK_PATTERNS[year.toString() as keyof TtpcTaskPatterns],
273+
},
274+
]),
276275
) as UniversityContestsTestData;
277276

278277
type TupcYear = '2022' | '2023';

0 commit comments

Comments
 (0)