File tree Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Original file line number Diff line number Diff line change 2
2
3
3
This GitHub Action requires writing the tests in Pull Requests, by requesting changes and posting a comment if tests are missing.
4
4
5
- To install it, copy and paste the following snippet into your ` .github/workflows/* .yml ` file.
5
+ To install it, copy and paste the following snippet into your ` .github/workflows/require-tests .yml ` file.
6
6
7
7
``` yaml
8
- - name : Require tests if source code is changed
9
- uses : infection/tests-checker-action@v1
10
- with :
11
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
8
+ name : ' Require tests if source code is changed'
9
+
10
+ on :
11
+ pull_request :
12
+ types : [opened]
13
+
14
+ jobs :
15
+ check :
16
+ runs-on : ubuntu-latest
17
+ steps :
18
+ - uses : infection/tests-checker-action@v1
19
+ with :
20
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
12
21
` ` `
13
22
14
23
<img width="990" alt="tests-checker" src="https://user-images.githubusercontent.com/3725595/45590526-b7f3fa00-b942-11e8-972d-143c0b367017.png">
You can’t perform that action at this time.
0 commit comments