Skip to content

Commit

Permalink
run test in dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
akomm committed Apr 8, 2019
1 parent 4544b37 commit 2c6c0fb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 7 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ composer test
Or with docker:

```bash
docker build . -t graphql-test && docker image prune -f >/dev/null && docker run --rm graphql-test test
composer docker -- test
composer docker -- test -- --filter=SomeTest
# optional: remove image when you do not need it anymore
composer docker-clean
```

Code quality
Expand All @@ -36,7 +39,9 @@ composer code-quality
Or with docker:

```bash
docker build . -t graphql-test && docker image prune -f >/dev/null && docker run --rm graphql-test code-quality
composer docker -- code-quality
# optional: remove image when you do not need it anymore
composer docker-clean
```

Coding Standard
Expand Down
4 changes: 3 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@
"@static-analysis",
"@bench",
"@check-cs"
]
],
"docker-clean": "docker image rm $(docker image ls -qf reference=graphql-test)",
"docker": "docker build . -t graphql-test && docker image prune -f >/dev/null && docker run --rm graphql-test"
}
}

0 comments on commit 2c6c0fb

Please sign in to comment.