Skip to content

Commit

Permalink
[Tests]: add weekly scheduled smoke tests
Browse files Browse the repository at this point in the history
  • Loading branch information
AriPerkkio committed Apr 21, 2021
1 parent d8590bb commit 409c10c
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/smoke-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Smoke test

on:
schedule:
- cron: '0 0 * * SUN'
workflow_dispatch:

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14
- run: |
npm install
npm link
npm link eslint-plugin-react
- uses: AriPerkkio/eslint-remote-tester-run-action@v1
with:
issue-title: "Results of weekly scheduled smoke test"
eslint-remote-tester-config: test/eslint-remote-tester.config.js
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ node_modules
!tests/**/node_modules
npm-debug.log
sftp-config.json
.cache-eslint-remote-tester
eslint-remote-tester-results

# Only apps should have lockfiles
yarn.lock
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@
"eslint-config-airbnb-base": "^14.2.1",
"eslint-plugin-eslint-plugin": "^2.3.0",
"eslint-plugin-import": "^2.22.1",
"eslint-remote-tester": "^1.1.0",
"eslint-remote-tester-repositories": "^0.0.1",
"espree": "^3.5.4",
"istanbul": "^0.4.5",
"markdown-magic": "^1.0.0",
Expand Down
40 changes: 40 additions & 0 deletions test/eslint-remote-tester.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
'use strict';

const eslintRemoteTesterRepositories = require('eslint-remote-tester-repositories');

module.exports = {
repositories: eslintRemoteTesterRepositories.getRepositories({randomize: true}),

pathIgnorePattern: eslintRemoteTesterRepositories.getPathIgnorePattern(),

extensions: ['js', 'jsx', 'ts', 'tsx'],

/** Empty array since we are only interested in linter crashes */
rulesUnderTesting: [],

concurrentTasks: 3,

/** Optional boolean flag used to enable caching of cloned repositories. For CIs it's ideal to disable caching. Defauls to true. */
cache: false,

eslintrc: {
root: true,
env: {
es6: true
},
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
jsx: true
}
},
settings: {
react: {
version: '16.13.1'
}
},
extends: ['plugin:react/all']
}
};

0 comments on commit 409c10c

Please sign in to comment.