Skip to content

Commit

Permalink
Feat/23 E2E (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
gpont committed Feb 23, 2022
1 parent bba8c5e commit e949300
Show file tree
Hide file tree
Showing 22 changed files with 27,425 additions and 890 deletions.
6 changes: 5 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,9 @@
"rules": {
"import/extensions": 0,
"import/prefer-default-export": 0
}
},
"ignorePatterns": [
"node_modules",
"e2e"
]
}
25 changes: 24 additions & 1 deletion .github/workflows/pull-request-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ jobs:

- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14'

- name: Installing deps
run: npm ci
Expand All @@ -27,21 +29,25 @@ jobs:

- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14'

- name: Installing deps
run: npm ci

- name: Check types
run: npm run ci:lint:types

Tests with coverage:
TestsWithCoverage:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14'

- name: Installing deps
run: npm ci
Expand All @@ -52,3 +58,20 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
test-command: yarn ci:test

E2E:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14'

- name: Installing deps
run: npm ci

- name: Run e2e
run: npm run ci:e2e
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ TS React functional components specific linting rules for ESLint
- [Contents](#contents)
- [Rules(docs)](#rulesdocs)
- [Running](#running)
- [Tests](#tests)
- [Unit tests](#unit-tests)
- [E2E tests](#e2e-tests)
- [Authors](#authors)
- [Contributing](#contributing)
- [License](#license)
Expand All @@ -23,12 +24,18 @@ TS React functional components specific linting rules for ESLint

## Running

### Tests
### Unit tests

```
npm run test
```

### E2E tests

```
npm run e2e:setup && npm run e2e:run
```

## Authors

- [@gpont](https://github.com/gpont)
Expand Down
24 changes: 24 additions & 0 deletions e2e/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"root": true,
"env": {
"browser": true
},
"extends": [
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "./tsconfig.json",
"ecmaVersion": "latest",
"sourceType": "module"
},
"plugins": [
"@typescript-eslint",
"typescript-react-fc"
],
"rules": {
"import/extensions": 0,
"import/prefer-default-export": 0,
"typescript-react-fc/prefer-react-fc": 1
}
}
72 changes: 72 additions & 0 deletions e2e/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Logs
logs
*.log
npm-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# nyc test coverage
.nyc_output

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Output of 'npm pack'
*.tgz

# dotenv environment variables file
.env
.env.test

# Dist folder
/dist

# Jest
/coverage

# Mac OS Trash
.DS_Store# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
Loading

0 comments on commit e949300

Please sign in to comment.