Skip to content

Commit 0459270

Browse files
authored
Merge pull request #189 from Lewiscowles1986/feature/gherkin-linting
2 parents 9d9caf8 + 6d47d7f commit 0459270

File tree

4 files changed

+360
-0
lines changed

4 files changed

+360
-0
lines changed

.gherkin-lintrc

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"indentation": [
3+
"on",
4+
{
5+
"Feature": 0,
6+
"Background": 2,
7+
"Scenario": 2,
8+
"Step": 4,
9+
"given": 4,
10+
"and": 4
11+
}
12+
],
13+
"no-dupe-feature-names": "on",
14+
"no-dupe-scenario-names": "off",
15+
"no-empty-file": "on",
16+
"no-files-without-scenarios": "on",
17+
"no-multiple-empty-lines": "on",
18+
"no-partially-commented-tag-lines": "on",
19+
"no-trailing-spaces": "on",
20+
"no-unnamed-features": "on",
21+
"no-unnamed-scenarios": "on",
22+
"no-scenario-outlines-without-examples": "on"
23+
}

.github/workflows/lint-gherkin.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Gherkin Linting
2+
3+
on: pull_request
4+
5+
jobs:
6+
7+
gherkin-lint:
8+
name: Lint Gherkin Feature files
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v1
12+
- uses: bahmutov/npm-install@v1
13+
- run: npm run lint

package-lock.json

Lines changed: 301 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"name": "scaffold-package-command",
3+
"version": "1.0.0",
4+
"description": "wp-cli/scaffold-package-command",
5+
"main": " ",
6+
"scripts": {
7+
"test": "echo \"Error: testing not setup\" && exit 1",
8+
"lint": "node ./node_modules/gherkin-lint/dist/main.js"
9+
},
10+
"repository": {
11+
"type": "git",
12+
"url": "git+https://github.com/wp-cli/scaffold-package-command.git"
13+
},
14+
"author": "Daniel Bachhuber <daniel@runcommand.io>",
15+
"license": "MIT",
16+
"bugs": {
17+
"url": "https://github.com/wp-cli/scaffold-package-command/issues"
18+
},
19+
"homepage": "https://github.com/wp-cli/scaffold-package-command#readme",
20+
"devDependencies": {
21+
"gherkin-lint": "^4.1.3"
22+
}
23+
}

0 commit comments

Comments
 (0)