-
-
Notifications
You must be signed in to change notification settings - Fork 131
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
CI: Allow running github actions on all branches #365
Conversation
pull_request: {} | ||
push: | ||
branches: | ||
- master | ||
- '*' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the idea of this section is that tests run on each pull request and again after a merge. This can catch errors when the PR feature branch wasn't up2date. Now if someone creates a PR based on a feature branch in this repo, not in a fork, will the tests run twice?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With branches : ['master']
, if someone creates a feature branch in this repo, no tests are running until merged in master where tests will run once.
If the feature branch is merged in master, tests will run while developing the feature branch then again when merged in master.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With branches : ['master'], if someone creates a feature branch in this repo, no tests are running until merged in master where tests will run once.
That's not correct. We've the pull_request: {}
setting to ensure tests run every PR, no matter in which repo the branch lives.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I said feature branch "in this repo", not a PR. Try forking the repo, create a feature branch, you will see the tests are not running.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now if someone creates a PR based on a feature branch in this repo, not in a fork, will the tests run twice?
Sorry, it took me sometime to figure out what you meant here and I had to experiment this myself in another unrelated repo. Yes, if the feature branch is made into a PR, the tests will run twice, once for the branch, once for the PR, which is not ideal although I am not sure how to prevent this.
My objective here was to have the tests running when someone forks and develops something in feature branch without having to make PR.
Remove Ruby 2.6 from matrix as it was now excluded from all testsFixed by PR Drop Ruby 2.6 leftovers in CI config #369Remove "spec tests" as it is the exact same as "Run tests"Fixed by PR CI: Dont run tests twice #375