Skip to content

Commit 409c10c

Browse files
committed
[Tests]: add weekly scheduled smoke tests
1 parent d8590bb commit 409c10c

File tree

4 files changed

+67
-0
lines changed

4 files changed

+67
-0
lines changed

.github/workflows/smoke-test.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Smoke test
2+
3+
on:
4+
schedule:
5+
- cron: '0 0 * * SUN'
6+
workflow_dispatch:
7+
8+
jobs:
9+
lint:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- uses: actions/setup-node@v1
14+
with:
15+
node-version: 14
16+
- run: |
17+
npm install
18+
npm link
19+
npm link eslint-plugin-react
20+
- uses: AriPerkkio/eslint-remote-tester-run-action@v1
21+
with:
22+
issue-title: "Results of weekly scheduled smoke test"
23+
eslint-remote-tester-config: test/eslint-remote-tester.config.js

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ node_modules
1919
!tests/**/node_modules
2020
npm-debug.log
2121
sftp-config.json
22+
.cache-eslint-remote-tester
23+
eslint-remote-tester-results
2224

2325
# Only apps should have lockfiles
2426
yarn.lock

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@
5252
"eslint-config-airbnb-base": "^14.2.1",
5353
"eslint-plugin-eslint-plugin": "^2.3.0",
5454
"eslint-plugin-import": "^2.22.1",
55+
"eslint-remote-tester": "^1.1.0",
56+
"eslint-remote-tester-repositories": "^0.0.1",
5557
"espree": "^3.5.4",
5658
"istanbul": "^0.4.5",
5759
"markdown-magic": "^1.0.0",

test/eslint-remote-tester.config.js

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
'use strict';
2+
3+
const eslintRemoteTesterRepositories = require('eslint-remote-tester-repositories');
4+
5+
module.exports = {
6+
repositories: eslintRemoteTesterRepositories.getRepositories({randomize: true}),
7+
8+
pathIgnorePattern: eslintRemoteTesterRepositories.getPathIgnorePattern(),
9+
10+
extensions: ['js', 'jsx', 'ts', 'tsx'],
11+
12+
/** Empty array since we are only interested in linter crashes */
13+
rulesUnderTesting: [],
14+
15+
concurrentTasks: 3,
16+
17+
/** Optional boolean flag used to enable caching of cloned repositories. For CIs it's ideal to disable caching. Defauls to true. */
18+
cache: false,
19+
20+
eslintrc: {
21+
root: true,
22+
env: {
23+
es6: true
24+
},
25+
parser: '@typescript-eslint/parser',
26+
parserOptions: {
27+
ecmaVersion: 2020,
28+
sourceType: 'module',
29+
ecmaFeatures: {
30+
jsx: true
31+
}
32+
},
33+
settings: {
34+
react: {
35+
version: '16.13.1'
36+
}
37+
},
38+
extends: ['plugin:react/all']
39+
}
40+
};

0 commit comments

Comments
 (0)