Skip to content

Commit e159eef

Browse files
committed
chore: correction erreurs notifiées par ESlint dans fichiers tests
1 parent 1689c07 commit e159eef

2 files changed

Lines changed: 3 additions & 6 deletions

File tree

tests/unit/core/chatbot/parsers/extractIntroduction.spec.mjs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,15 @@ describe("extractInformationsFromInitialMessage", () => {
8484

8585
it("handles obfuscation when enabled", () => {
8686
const obfuscatedYaml = { obfuscate: true };
87-
const input = `1. [text](obfuscated Link)`;
88-
const [_, choices] = extractInformationsFromInitialMessage(
87+
const input = `Test\n1. [text](obfuscated Link)`;
88+
const [content, choices] = extractInformationsFromInitialMessage(
8989
input,
9090
obfuscatedYaml,
9191
);
9292

9393
const expectedLink = btoa("obfuscated Link");
9494
expect(choices[0][1]).toBe(expectedLink);
95+
expect(content).toEqual(["Test"]);
9596
});
9697

9798
it("returns only content when no list is found", () => {

tests/unit/utils/arrays.spec.mjs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -119,10 +119,6 @@ describe("shuffleArray", () => {
119119
});
120120

121121
describe("randomizeArrayWithFixedElements", () => {
122-
function isSameOrder(a, b) {
123-
return a.every((val, idx) => val === b[idx]);
124-
}
125-
126122
it("returns an array of the same length as the input", () => {
127123
const input = [
128124
["A", 0, false],

0 commit comments

Comments
 (0)