-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Migrate to a hybrid of GH actions and Travis #5183
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
Conversation
julienfalque
left a comment
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.
Damn, I was working on this too, but you were faster than me :)
|
Shouldn't the jobs appear in the checks of this PR? |
|
Related: PHPUnitGoodPractices/Traits#48. |
No, not until this is merged. |
4f83cf9 to
42550bf
Compare
|
Looks like the accessible object package is causing us issues. We need to mark it as compatible with PHP 8 and remove the HHVM conflict. |
|
Looks like these tests have actually highlighted issues with our minimum symfony console versions. |
fac9e94 to
f040faa
Compare
f040faa to
3f18c51
Compare
3f18c51 to
8edfa38
Compare
|
This is passing, and could be merged right away. A follow up PR can remove the rest of the travis jobs. |
|
@GrahamCampbell The PR is still a draft, shall we mark it as ready for review? |
|
@GrahamCampbell , can you talk to creator of #5268 and align how to achieve best outcome together ;) |
| * @group auto-review | ||
| * @group covers-nothing | ||
| */ | ||
| final class TravisTest extends TestCase |
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.
👎 for dropping
i would rather expecting to have those tests migrated to read github actions config than fully dropped.
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.
Do you consider this a blocker for merging? I feel like the GitHub UI already makes it pretty clear if stuff is missing, with the human readable job names I have gone for.
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.
yes, I do
but pls, align with @sanmai to prepare single PR instead of putting more effort in one or another PR
sanmai
left a comment
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.
This is a fine PR, but since it has a lot if if:s, and separate jobs for different OSes (where it should have just used matrix), it'll be a headache to support.
| - name: Set git to use LF | ||
| run: | | ||
| git config --global core.autocrlf false | ||
| git config --global core.eol lf |
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.
Why is this required?
I haven't seen anything bad happen without these lines.
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.
Tests fail without I think.
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.
Haven't seen this in other repos - can we try without this? Would be easier not to worry that this might affect some tests.
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.
Are you sure? I have a workflow which does not fail without this on Windows.
| - name: Set git to use LF | ||
| run: | | ||
| git config --global core.autocrlf false | ||
| git config --global core.eol lf |
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.
Haven't seen this in other repos - can we try without this? Would be easier not to worry that this might affect some tests.
| tools: composer:snapshot | ||
| coverage: none | ||
|
|
||
| - name: Setup problem matchers |
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.
What is this? Can you elaborate or link to some PR when it is run or better - failing a build for good reason?
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.
Shows test failures inline on diffs on github's ui.
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.
Is it? I don't think I can reproduce: https://github.com/sanmai/phpunit-primer/pull/6/files
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.
Yes, that stuff works properly. It's exactly as documented in https://github.com/shivammathur/setup-php#phpunit.
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.
Well, the thing is I made a test to fail intentionally, added these matchers, and there's nothing. How can we verify that this thing actually works?
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.
@GrahamCampbell why closing the thread? looks like the question is still open
| run: PHP_CS_FIXER_FUTURE_MODE=1 PHP_CS_FIXER_IGNORE_ENV=1 php php-cs-fixer --diff --dry-run -v fix | ||
| if: "matrix.php == '8.0'" | ||
|
|
||
| windows: |
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.
Why do we need this? Why OS cannot be part of matrix?
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.
Each OS is different, and in the end, trying to put it all into one single thing ends up an absolute mess. Sometimes duplication is least worst. Certainly makes the config file more readable.
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.
not sure, here it was added without that "absolute mess"
https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/5268/files#diff-944291df2c9c06359d37cc8833d182d705c9e8c3108e7cfe132d61a06e9133ddR33
7924e09 to
a6b64e4
Compare
| uses: shivammathur/setup-php@v2 | ||
| with: | ||
| php-version: ${{ matrix.php }} | ||
| tools: composer |
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.
This is as redundant as before.
This PR was merged into the 2.16 branch. Discussion ---------- Add yamllint workflow, validates .yaml files This has two effects: - It will validate `.yaml` files for general correctness everywhere except `vendor` and `dev-tools/vendor` - And as a side-effect, it might enable other workflows to happen. E.g. we will no longer need to consult with forks to see if #5295 #5268 #5183 etc are working. Commits ------- f6cdee1 Add yamllint workflow
|
If someone else wants to finish this, they should take over from here. |
|
Thanks for your effort on this PR, @GrahamCampbell . |
Removes circle and appveyor, and some of the travis jobs. Long term, we could probably remove travis, but this is not necessary yet. The purpose of this PR is to have fast robust testing across multiple PHP versions and OSs, and not for overkill consolidation, taking extra developer time without significant benefit.