mirror of
https://github.com/zkldi/Tachi.git
synced 2026-09-29 10:28:04 +03:00
rename some invalid percent and date errs
This commit is contained in:
@@ -162,7 +162,7 @@ export function ParseDateFromString(str: string | undefined | null): number | nu
|
||||
const date = Date.parse(str);
|
||||
|
||||
if (Number.isNaN(date)) {
|
||||
throw new InvalidScoreFailure(`Could not convert date ${str} to number.`);
|
||||
throw new InvalidScoreFailure(`Invalid/Unparsable score timestamp of ${str}.`);
|
||||
}
|
||||
|
||||
return date;
|
||||
|
||||
@@ -379,7 +379,7 @@ t.test("#ConverterFn", (t) => {
|
||||
importType,
|
||||
logger
|
||||
),
|
||||
{ message: /Invalid score of 2000, produced percent of 127/u } as any
|
||||
{ message: /Invalid percent/u } as any
|
||||
);
|
||||
|
||||
t.end();
|
||||
|
||||
@@ -127,7 +127,7 @@ t.test("#ConvertFileMerIIDX", (t) => {
|
||||
|
||||
t.test("Invalid Date", (t) => {
|
||||
t.rejects(() => merc({ update_time: "INVALID" }), {
|
||||
message: /Invalid score timestamp of INVALID/u,
|
||||
message: /Invalid percent/u,
|
||||
} as any);
|
||||
|
||||
t.end();
|
||||
|
||||
@@ -178,7 +178,7 @@ t.test("#ConverterIRFervidex", (t) => {
|
||||
"ir/fervidex",
|
||||
logger
|
||||
),
|
||||
{ message: /Invalid score of 9999 for chart.*Resulted in percent/giu } as any
|
||||
{ message: /Invalid percent/giu } as any
|
||||
);
|
||||
|
||||
t.end();
|
||||
|
||||
Reference in New Issue
Block a user