Skip to content

Commit

Permalink
Make engine build configs test exempt (#3405)
Browse files Browse the repository at this point in the history
For example for PRs like flutter/engine#49776
  • Loading branch information
zanderso authored Jan 12, 2024
1 parent 919cc8a commit 777d7cc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,8 @@ class GithubWebhookSubscription extends SubscriptionHandler {
!_isTestExempt(filename) &&
// License goldens are auto-generated.
!filename.startsWith('ci/licenses_golden/') &&
// Build configuration files tell CI what to run.
!filename.startsWith('ci/builders/') &&
// Build files don't need unit tests.
!filename.endsWith('.gn') &&
!filename.endsWith('.gni')) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1523,7 +1523,7 @@ void foo() {
);
});

test('Engine labels PRs, no comment for license goldens', () async {
test('Engine labels PRs, no comment for license goldens or build configs', () async {
const int issueNumber = 123;

tester.message = generateGithubWebhookMessage(
Expand All @@ -1534,9 +1534,10 @@ void foo() {
);

when(pullRequestsService.listFiles(Config.engineSlug, issueNumber)).thenAnswer(
(_) => Stream<PullRequestFile>.value(
(_) => Stream<PullRequestFile>.fromIterable(<PullRequestFile>[
PullRequestFile()..filename = 'ci/licenses_golden/licenses_dart',
),
PullRequestFile()..filename = 'ci/builders/linux_unopt.json',
]),
);

await tester.post(webhook);
Expand Down

0 comments on commit 777d7cc

Please sign in to comment.