Skip to content
This repository was archived by the owner on Nov 27, 2023. It is now read-only.

Commit 9550737

Browse files
authored
Merge pull request #318 from KnisterPeter/wallaby
chore: add wallaby config
2 parents ccd7bd2 + 8db1586 commit 9550737

File tree

3 files changed

+32
-8
lines changed

3 files changed

+32
-8
lines changed

tests/parsing-test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,10 @@ import * as path from 'path';
77

88
import * as react2dts from '../src/index';
99

10-
const basedir = path.join(__dirname, '..', '..', 'tests');
10+
let basedir = path.join(__dirname, '..', '..', 'tests');
11+
if (process.env.WALLABY) {
12+
basedir = path.join(__dirname);
13+
}
1114

1215
function normalize(input: string): string {
1316
return input

tsconfig.json

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
{
22
"compilerOptions": {
3+
"alwaysStrict": true,
34
"declaration": true,
5+
"lib": [
6+
"dom",
7+
"es5",
8+
"es2015.iterable",
9+
"es2015.promise"
10+
],
411
"listFiles": false,
512
"module": "commonjs",
613
"noFallthroughCasesInSwitch": true,
@@ -14,13 +21,7 @@
1421
"strictNullChecks": true,
1522
"stripInternal": true,
1623
"suppressImplicitAnyIndexErrors": true,
17-
"target": "es5",
18-
"lib": [
19-
"dom",
20-
"es5",
21-
"es2015.iterable",
22-
"es2015.promise"
23-
]
24+
"target": "es5"
2425
},
2526
"exclude": [
2627
"index.d.ts",

wallaby.conf.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
module.exports = function(wallaby) {
2+
process.env.WALLABY = 'true';
3+
return {
4+
files: [
5+
'src/**/*.ts',
6+
{pattern: 'tests/**/*.js*', instrument: false},
7+
{pattern: 'tests/**/*.d.ts', instrument: false},
8+
{pattern: 'node_modules/dts-dom/package.json', instrument: false},
9+
{pattern: 'node_modules/dts-dom/bin/index.d.ts', instrument: false}
10+
],
11+
tests: [
12+
'tests/**/*-test.ts'
13+
],
14+
env: {
15+
type: 'node'
16+
},
17+
testFramework: 'ava',
18+
debug: false
19+
};
20+
}

0 commit comments

Comments
 (0)