Skip to content

Commit 476a8c4

Browse files
committed
- small cleanup
1 parent 0aab575 commit 476a8c4

File tree

4 files changed

+30
-14
lines changed

4 files changed

+30
-14
lines changed

jest.config.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
// jest.config.js
22
import { createJsWithTsEsmPreset } from "ts-jest";
3+
34
export default {
45
clearMocks: true,
56
testEnvironment: "node",
67
testMatch: ["**/*.test.ts"],
78
testRunner: "jest-circus/runner",
89
moduleNameMapper: {
9-
"(.+)\\.js": "$1",
10+
"(.+)\\.js": "$1"
1011
},
11-
...createJsWithTsEsmPreset(),
12-
}
12+
...createJsWithTsEsmPreset()
13+
};

src/annotator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import * as github from '@actions/github'
44
// eslint-disable-next-line import/extensions
55
import {SummaryTableRow} from '@actions/core/lib/summary.js'
66
// eslint-disable-next-line import/extensions
7-
import {GitHub, context} from '@actions/github/lib/utils.js'
7+
import {context, GitHub} from '@actions/github/lib/utils.js'
88
import {buildTable} from './utils.js'
99

1010
export async function annotateTestResult(

src/main.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import * as core from '@actions/core'
22
import * as github from '@actions/github'
33
import {annotateTestResult, attachComment, attachSummary} from './annotator.js'
4-
import {TestResult, parseTestReports} from './testParser.js'
4+
import {parseTestReports, TestResult} from './testParser.js'
55
import {buildTable, readTransformers, retrieve} from './utils.js'
66
// eslint-disable-next-line import/extensions
77
import {GitHub} from '@actions/github/lib/utils.js'

tsconfig.json

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,31 @@
11
{
22
"compilerOptions": {
3-
"target": "ESNext", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
4-
"module": "NodeNext", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
5-
"outDir": "./lib", /* Redirect output structure to the directory. */
6-
"rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
7-
"strict": true, /* Enable all strict type-checking options. */
8-
"noImplicitAny": true, /* Raise error on expressions and declarations with an implied 'any' type. */
3+
/* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
4+
"target": "ESNext",
5+
/* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
6+
"module": "NodeNext",
7+
/* Redirect output structure to the directory. */
8+
"outDir": "./lib",
9+
/* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
10+
"rootDir": "./src",
11+
/* Enable all strict type-checking options. */
12+
"strict": true,
13+
/* Raise error on expressions and declarations with an implied 'any' type. */
14+
"noImplicitAny": true,
915
"strictPropertyInitialization": true,
1016
"noImplicitThis": true,
1117
"moduleResolution": "Node16",
12-
"esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
13-
"lib": [ "ESNext","ES2021.String", "dom"] /* Enable custom `ES2021.String` extension in typescript for `replaceAll` */
18+
/* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
19+
"esModuleInterop": true,
20+
/* Enable custom `ES2021.String` extension in typescript for `replaceAll` */
21+
"lib": [
22+
"ESNext",
23+
"ES2021.String",
24+
"dom"
25+
]
1426
},
15-
"exclude": ["node_modules", "__tests__/**.ts"],
27+
"exclude": [
28+
"node_modules",
29+
"__tests__/**.ts"
30+
]
1631
}

0 commit comments

Comments
 (0)