[dev] When to require, suggest or require-dev Re: PHPUnit 9.5 compat

Jan Schneider jan at horde.org
Sun Mar 28 11:20:06 UTC 2021


Zitat von Ralf Lang <lang at b1-systems.de>:

> Hello,
>
>
>> A colleague and I began converting some library unit tests to phpunit 9.
>>
>> This meant
>
> While upgrading the unit test for horde/date to github actions, phpunit
> 9, I stumbled across a little problem.
>
> Some unit tests require but don't check for the horde/icalendar library.
>
> https://github.com/maintaina-com/Date/runs/2141049425?check_suite_focus=true
>
> Icalendar is only suggested for horde/date but no dependency.
>
> What would be the right path here?
>
> - make the icalendar library a require-dev
> - install all suggests for unit testing
> - Make the tests skip on missing optional dependency

Good question. Does compser support at package at both places,  
require-dev and suggests? If not, then the 2nd option.

-- 
Jan Schneider
The Horde Project
https://www.horde.org/



More information about the dev mailing list