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
Add appveyor.yml for C.I. on Windows #15575
Conversation
nicolas-grekas
commented
Aug 18, 2015
Q | A |
---|---|
Bug fix? | yes |
New feature? | no |
BC breaks? | no |
Deprecations? | no |
Tests pass? | YES, both on Travis (Linux) and on Appveyor (Windows)! |
Fixed tickets | #13934, #15049, #14259, #15045, #15444 |
License | MIT |
Doc PR | symfony/symfony-docs#5654 |
- testing two matrix lines:
- one without mbtring nor fileinfo nor intl
- one with these ext enables, intl version 51.2 so that almost no test is skipped on our Intl component
- bug fixes thanks to these harder testing conditions
- some display bug on appveyor, reported here.
should we also try compiling the debug extension on Windows ? Or should we wait until we decide whether we move it to a separate repo ? |
- php composer.phar install --prefer-dist --no-interaction | ||
test_script: | ||
- cd C:\projects\symfony | ||
- php -r "readfile('https://phar.phpunit.de/phpunit.phar');" | php |
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 about using native ways to download files instead ? http://www.appveyor.com/docs/how-to/download-file
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.
btw, this is already done for the php.zip file.
and downloading phpunit should also be part of the installation rather than the 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.
Because I'd prefer having commands read/writables by us. And also because cakephp does this way :)
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.
but the current comment could have issues. see https://github.com/symfony/symfony-installer/issues/137
That would be great to have the debug ext compiled also, but let's first make this one work. |
Account has been created now. Try to push here to trigger a new build as I don't seem to have any way to do that from the interface. |
d252957
to
c658d49
Compare
@fabpot thanks, did you setup the webhook? |
2197a23
to
32932f5
Compare
- echo extension=php_mbstring.dll >> php.ini | ||
- echo extension=php_fileinfo.dll >> php.ini | ||
- php -r "readfile('https://getcomposer.org/installer');" | php | ||
- echo @php c:\php\composer.phar %*>composer.bat |
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.
your composer bat file does not work
7b474b0
to
646b0db
Compare
The build is now working! But phpunit crashes before going to the end of the test suite :( |
- php c:\php\composer.phar install --prefer-dist --no-progress | ||
- mkdir phpunit | ||
- cd phpunit | ||
- ps: Start-FileDownload 'https://github.com/sebastianbergmann/phpunit/archive/4.7.zip' |
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 current stable version of PHPUnit is 4.8, not 4.7
@nicolas-grekas can you try running the testsuite in smaller chunks (component by component) to see whether it helps ? We are not running the full testsuite in 1 go on Travis (even though the main goal was to parallelize runs to be faster) |
646b0db
to
37e1d49
Compare
If you give me the command to do so, yes :)
|
37e1d49
to
0526ee8
Compare
Any PowerShell scripter here? We would need a ps script to run phpunit tests in parallel, the same as we do on unixes with Invole-Parallel could maybe help, but I must admit I'm a total noob here. |
0526ee8
to
5d461b9
Compare
An other idea could be to run bash from cygwin, it's maybe even already somewhere on the vm. |
@nicolas-grekas I have both powershell and cygwin on my PC, what do you want me to do/try? |
f653ba4
to
ccc91e9
Compare
Status: needs review |
e044e77
to
aa357f8
Compare
@@ -38,11 +38,16 @@ public function testConstructorDefaultTimeZone() | |||
$formatter = $this->getDateFormatter('en', IntlDateFormatter::MEDIUM, IntlDateFormatter::SHORT); | |||
|
|||
// In PHP 5.5 default timezone depends on `date_default_timezone_get()` method | |||
if (PHP_VERSION_ID >= 50500) { | |||
if (PHP_VERSION_ID >= 50500 || (extension_loaded('intl') && method_exists('IntlDateFormatter', 'setTimeZone'))) { |
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.
pecl intl 3.0 backports php5.5 behavior to 5.3/5.4
aa357f8
to
d83ac63
Compare
@@ -568,8 +570,16 @@ public function setTimeZoneId($timeZoneId) | |||
|
|||
try { | |||
$this->dateTimeZone = new \DateTimeZone($timeZoneId); | |||
if ('GMT' !== $timeZoneId && $this->dateTimeZone->getName() !== $timeZoneId) { |
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.
Some invalid timezones are accepted by DateTimeZone since 5.5.10, but rejected by IntlDateFormatter.
ping @symfony/deciders , especially @webmozart |
d83ac63
to
6a0d181
Compare
f01bff8
to
05efbe1
Compare
05efbe1
to
ea5d656
Compare
Not mergeable yet as there is still a failing test on Windows. |
Thank you @nicolas-grekas. |
This PR was merged into the 2.3 branch. Discussion ---------- Add appveyor.yml for C.I. on Windows | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | YES, both on Travis (Linux) and on Appveyor (Windows)! | Fixed tickets | #13934, #15049, #14259, #15045, #15444 | License | MIT | Doc PR | symfony/symfony-docs#5654 - testing two matrix lines: - one without mbtring nor fileinfo nor intl - one with these ext enables, intl version 51.2 so that almost no test is skipped on our Intl component - bug fixes thanks to these harder testing conditions - some display bug on appveyor, [reported here](http://help.appveyor.com/discussions/suggestions/197-support-ansi-color-codes). Commits ------- ea5d656 Windows and Intl fixes 8bbd8d9 Add appveyor.yml for C.I. on Windows
install: | ||
- IF EXIST c:\php (SET PHP=0) ELSE (mkdir c:\php) | ||
- cd c:\php | ||
- IF %PHP%==1 appveyor DownloadFile http://windows.php.net/downloads/releases/archives/php-5.4.43-nts-Win32-VC9-x86.zip |
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.
@nicolas-grekas why testing against PHP 5.4 which is nearly EOL rather than against PHP 5.6 ?
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.
because I couldn't find a .dll for intl + icu 51.2 for 5.5 (vc9-nts-x86)
This PR was merged into the 2.3 branch. Discussion ---------- Doc about new way of running tests | Q | A | ------------- | --- | Doc fix? | yes | New docs? | yes | Applies to | all | Fixed tickets | - Related to symfony/symfony#15575 Commits ------- dc754c8 Doc about new way of running tests