Skip to content

Commit 7bc6877

Browse files
committed
ci(workflows): 👷 test previous node versions
1 parent aa63480 commit 7bc6877

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

.github/workflows/development.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
strategy:
2020
matrix:
2121
os: [ubuntu-latest, macos-latest, windows-latest]
22-
node-version: [12.x, 16.x, 17.x]
22+
node-version: [10.x, 12.x, 13.x, 14.x, 15.x, 16.x, 17.x]
2323

2424
steps:
2525
- uses: actions/checkout@v2

src/index.spec.ts

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ import * as TestSubject from '.';
44
const toJson = (keys: string[], row: string[]) => {
55
// eslint-disable-next-line @typescript-eslint/no-explicit-any
66
const object = {} as any;
7-
for (const [keyIndex, key] of keys.entries()) {
7+
// eslint-disable-next-line unicorn/no-array-for-each
8+
keys.forEach((key, keyIndex) => {
89
object[key] = row[keyIndex];
9-
}
10-
10+
});
1111
return object;
1212
};
1313

@@ -202,7 +202,8 @@ describe(`${TestSubject.libname} ${TestSubject.libversion} - csv`, () => {
202202
const testSubject = new TestSubject.Parser();
203203
const rows = testSubject.parse('1,2,3\n,b,c');
204204

205-
const wrows = rows as unknown as Array<string[]>;
205+
// eslint-disable-next-line prettier/prettier
206+
const wrows = (rows as unknown) as Array<string[]>;
206207
expect.assertions(3);
207208

208209
expect(() => {
@@ -230,7 +231,8 @@ describe(`${TestSubject.libname} ${TestSubject.libversion} - csv`, () => {
230231
const testSubject = new TestSubject.Parser();
231232
testSubject.parse('1,2,3\n,b,c');
232233

233-
const wrows = testSubject.rows as unknown as Array<string[]>;
234+
// eslint-disable-next-line prettier/prettier
235+
const wrows = (testSubject.rows as unknown) as Array<string[]>;
234236
expect.assertions(3);
235237

236238
expect(() => {
@@ -258,7 +260,8 @@ describe(`${TestSubject.libname} ${TestSubject.libversion} - csv`, () => {
258260
const testSubject = new TestSubject.Parser();
259261
testSubject.parse('1,2,3\n,b,c');
260262

261-
const wrows = testSubject.json as unknown as Array<
263+
// eslint-disable-next-line prettier/prettier
264+
const wrows = (testSubject.json as unknown) as Array<
262265
Record<string, string>
263266
>;
264267
expect.assertions(2);

0 commit comments

Comments
 (0)