Skip to content
This repository was archived by the owner on Apr 13, 2025. It is now read-only.

Commit b9839c1

Browse files
committed
Merge branch 'master' into feature/semantic-release
2 parents aa58e47 + 1cd4d55 commit b9839c1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+17635
-14053
lines changed

.eslintrc.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,7 @@ module.exports = {
44
ecmaVersion: 2017,
55
sourceType: "module",
66
},
7-
extends: [
8-
"eslint:recommended",
9-
"plugin:@typescript-eslint/recommended",
10-
],
7+
extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended"],
118
// Don't traverse fs up to root.
12-
root: true
9+
root: true,
1310
};

.github/workflows/ci.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,23 @@ name: CI
33
on: [push, pull_request]
44
jobs:
55
build:
6-
runs-on: ubuntu-latest
6+
strategy:
7+
matrix:
8+
os: [ubuntu-latest, windows-latest]
9+
node: [12, 15]
10+
11+
runs-on: ${{ matrix.os }}
712
steps:
813
- uses: actions/checkout@v2
914
- uses: actions/setup-node@v2
1015
with:
11-
node-version: 15
16+
node-version: ${{ matrix.node }}
1217

1318
- name: Install nodejs dependencies
1419
run: npm ci
1520

1621
- name: Build TS
1722
run: npm run build
23+
24+
- name: Run tests
25+
run: npm run test

.gitignore

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,11 @@ build/
33
node_modules/
44

55
# nodecg to test features
6-
nodecg/
6+
nodecg/
7+
8+
# Test coverage output
9+
coverage/
10+
11+
# IDEs / Text editors
12+
.idea/
13+
.vscode/

.prettierignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
nodecg
1+
nodecg
2+
build

.prettierrc.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ module.exports = {
1010
{
1111
files: "*.md",
1212
options: {
13-
tabWidth: 2
14-
}
15-
}
16-
]
13+
tabWidth: 2,
14+
},
15+
},
16+
],
1717
};

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
// but the entry-point needs to be executable so we can't have it in src/index.ts directly
66
// because the resulting file won't have the executable flag and you can't properly use it that way.
77

8-
require("./build/index");
8+
require("./build/src/index");

jest.config.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
preset: "ts-jest",
3+
testEnvironment: "node",
4+
// We don't want to test nodecg, and without including it jest fails because it includes a invalid json
5+
modulePathIgnorePatterns: ["/nodecg/"],
6+
testMatch: ["<rootDir>/test/**/*.ts", "!**/*.util.ts"],
7+
};

0 commit comments

Comments
 (0)