Commit graph

25 commits

Author SHA1 Message Date
Simon Engledew
456cd431ff
Improve test coverage 2021-01-04 12:05:37 +00:00
Simon Engledew
1511db33b3
Only check the steps of the job currently being run 2021-01-04 12:00:15 +00:00
Simon Engledew
e89a24b8cb
Only report the first CheckoutWrongHead lint error 2020-12-21 11:08:49 +00:00
Simon Engledew
2d00e8c6f7
Fix for numerical branch names 2020-12-18 10:23:46 +00:00
Simon Engledew
18c6a7d6d1
fix another edge case 2020-12-04 15:18:22 +00:00
Simon Engledew
7100f22932
Add a bunch of tests cases and harden the function aganst malformed workflows 2020-12-03 13:41:55 +00:00
Simon Engledew
107fe8422f
Add advanced test case 2020-12-02 08:48:34 +00:00
Simon Engledew
698e2a5487
Just convert the pattern into a RegExp... 2020-12-01 20:56:07 +00:00
Simon Engledew
4d862616ce
First iteration on feedback 2020-12-01 20:08:41 +00:00
Simon Engledew
b1be00db57
Test the branch patterns work both ways 2020-12-01 17:16:33 +00:00
Simon Engledew
145a3c1ed9
Add more wildcard examples 2020-12-01 15:33:27 +00:00
Simon Engledew
14719432ef
Add more test cases 2020-12-01 15:30:11 +00:00
Simon Engledew
c8ee1f4ef3
Handle wildcard branches 2020-12-01 15:21:30 +00:00
Simon Engledew
ac1c081de8
Handle the case where branches may be strings, including "*" 2020-12-01 12:03:50 +00:00
Simon Engledew
be09fb3e99
Implement feedback 2020-11-26 15:20:38 +00:00
Simon Engledew
92ffb08081
Tidy up ready for review 2020-11-24 17:21:25 +00:00
Simon Engledew
2ac22e8935
Send short codes that do not need URL encoding for better splunk tracing 2020-11-24 12:43:08 +00:00
Simon Engledew
6df1fc5e38
Do not fail if the workflow has been deleted 2020-11-24 10:51:31 +00:00
Simon Engledew
754f502a84
Workflow triggers are null if unspecified 2020-11-24 10:25:58 +00:00
Simon Engledew
33bb87523e
Write a warning if there is an error with the workflow 2020-11-24 09:51:00 +00:00
Simon Engledew
7eb9dfcc60
Add a function that can lint a CodeQL action workflow 2020-11-23 17:29:19 +00:00
Simon Engledew
1c8d72e0c2
Remove unnecessary env manipulation
testing-utils.ts / setupTests() already stores and restores the env
2020-11-04 10:59:35 +00:00
Simon Engledew
5c0e2f93f1
Fix invalid API call when running locally
The method getAnalysisKey would call getWorkflowPath and raise an API Error.

This change follows the pattern in prepareLocalRunEnvironment to set a dummy value for the required environment variable, therefore shortcutting the API request.
2020-11-04 09:58:09 +00:00
Robin Neatherway
7795860c11 Do not always overwrite the GITHUB_REF for PRs
As we move towards analysing the merge commit for pull requests by
default, we should stop sending `/refs/pull/n/head` rather than
`refs/pull/n/merge` _unless_ the checked-out SHA has actually changed.
Here we assume that any change (compared to GITHUB_SHA) indicates that
`git checkout HEAD^2` has been run earlier. This may sometimes be
incorrect (e.g. `git checkout mybranch`), but in that case the ref
would be wrong either way.
2020-09-17 13:11:06 +01:00
Robert Brignull
121fd331cd Introduce actions-util.ts 2020-09-15 14:01:21 +01:00