Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CI Triggers #2763

Merged
merged 2 commits into from
Mar 19, 2020
Merged

Update CI Triggers #2763

merged 2 commits into from
Mar 19, 2020

Conversation

hsubox76
Copy link
Contributor

Previously:

  • "Run All Tests" ran when (1) a pull_request was closed and (2) the target branch was master. This left out some cases where we would want to run all tests, such as a direct merge to master.
  • "Push/PR" ran tests on changed files, but the it runs 2 tests (1 each on the push trigger and PR trigger) that are redundant in most cases, and the "push" version may not diff correctly if the branch is stale, and may run too many tests.

Now:

  • "Run All Tests" workflow is triggered on push to any branch. (Canary Deploy job only runs if the branch was master.)
  • "Push/PR" renamed to "Test Modified Packages" and runs only on PR events (opened, synchronized, reopened) on any branch except master. This still may happen to run all tests if a key top level file was changed.
  • "Cross Browser Test Flow" only runs on push to master.

Additionally, we will change the repo settings to ensure "Test Modified Packages" is a required check and "Run All Tests" is optional, so if it runs too many tests and fails a flaky test, it does not block merge.

@@ -1,11 +1,7 @@
name: Run All Tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the other workflow is renamed to "Test Modified Packages", how about also renaming this one to "Test All Packages"?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

- master
types:
- closed
push:
schedule:
- cron: '0 6,18 * * *'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need the cron job?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess it hasn't been very helpful. Removing.

pull_request:
branches:
- '*'
- '!master'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does excluding master for PR mean? Don't we always create PR against master?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I think I was confused about what "branches" means for PR. Fixing.

Copy link
Contributor

@yifanyang yifanyang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not a code owner, but LGTM!

@hsubox76 hsubox76 merged commit cbc191d into master Mar 19, 2020
@hsubox76 hsubox76 deleted the ch-workflow branch April 3, 2020 18:54
@firebase firebase locked and limited conversation to collaborators Apr 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants