mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2024-09-20 15:26:15 +08:00
ci(frontend/scripts): print expected quote length (#4499) gforien
This commit is contained in:
parent
193a708572
commit
8bebb8c54a
|
@ -406,17 +406,16 @@ function validateQuotes() {
|
|||
}
|
||||
const incorrectQuoteLength = quoteData.quotes
|
||||
.filter((quote) => quote.text.length !== quote.length)
|
||||
.map((quote) => quote.id);
|
||||
if (incorrectQuoteLength.length !== 0) {
|
||||
console.log(
|
||||
`Quote ${quotefilename} ID(s) ${incorrectQuoteLength.join(
|
||||
","
|
||||
)} length fields are \u001b[31mincorrect\u001b[0m`
|
||||
);
|
||||
console.log("Some length fields are \u001b[31mincorrect\u001b[0m");
|
||||
incorrectQuoteLength
|
||||
.map((quote) => { console.log(
|
||||
`Quote ${quotefilename} ID ${quote.id}: expected length ${quote.text.length}`
|
||||
)});
|
||||
quoteFilesAllGood = false;
|
||||
incorrectQuoteLength.map((id) => {
|
||||
incorrectQuoteLength.map((quote) => {
|
||||
quoteLengthErrors.push(
|
||||
`${quotefilename} ${id} length field is incorrect`
|
||||
`${quotefilename} ${quote.id} length field is incorrect`
|
||||
);
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue