mirror of
https://github.com/lukaszraczylo/ghtracker.git
synced 2026-10-12 00:45:38 +00:00
fix(collector): include fork pull requests in pr_open
External contributors open pull requests from forks. The pr_open alert now covers them, so the review action sees them. The consumer must treat fork pull requests as untrusted.
This commit is contained in:
@@ -43,7 +43,10 @@ func TestAutoRunner(t *testing.T) {
|
||||
authors []string
|
||||
steps []autoStep
|
||||
}{
|
||||
"fork skipped": {steps: []autoStep{{[]model.PullRequest{autoPR(1, "a", "x", fork)}, 200, 0}}},
|
||||
"fork triggers once per sha": {steps: []autoStep{
|
||||
{[]model.PullRequest{autoPR(1, "a", "x", fork)}, 200, 1},
|
||||
{[]model.PullRequest{autoPR(1, "a", "x", fork)}, 200, 0},
|
||||
}},
|
||||
"draft skipped": {steps: []autoStep{{[]model.PullRequest{autoPR(1, "a", "x", draft)}, 200, 0}}},
|
||||
"author filter": {authors: []string{"Alice"}, steps: []autoStep{
|
||||
{[]model.PullRequest{autoPR(1, "a", "bob", nil), autoPR(2, "b", "alice", nil)}, 200, 1},
|
||||
|
||||
Reference in New Issue
Block a user