u01jmg3 / ics-parser

Parser for iCalendar Events • PHP 8+, 7 (≥ 7.4), 5 (≥ 5.6)
MIT License
448 stars 144 forks source link

Upgrade `phpunit/phpunit` dev-dependency to 5.x #279

Closed s0600204 closed 3 years ago

s0600204 commented 3 years ago

The version used previously (4.8.36) was using the core php function each() which was deprecated in php 7.2 and removed for php 8.0. As such, developers running webservers with php 8 were no longer able to run tests.

As of this PR, we now rely on a slightly more recent version of phpunit (5.7.27), which also requires us to bump our minimum supported version of php to 5.6.

Refs. https://www.php.net/manual/en/function.each


As an aside, it looks like phpunit 6.0 requires php 7.0 as a minimum - and there's probably unlikely to ever be a newer version of phpunit 5 - so this is most likely as far as we can go with phpunit and still support some flavour of php 5.

u01jmg3 commented 3 years ago
s0600204 commented 3 years ago
  • Do you know exactly what version of PHP 5.6.x would be needed?

I do not, although admittedly I haven't looked further than phpunit's Packagist page (https://packagist.org/packages/phpunit/phpunit#5.7.27).

  • Looks like I would have to release this as v3 of the parser

Understandable. Figured it was worth creating the PR just so that you were aware of the issue (and had a fix to hand).