Re: Self Introduction: Otto Urpelainen

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Otto,

Welcome on the PHP SIG.

Le 19/07/2021 à 21:04, Otto Urpelainen a écrit :

There is one more field where I would like to see improvement: Test execution. The two projects I have been looking at this far have both used a system where the source actually includes tests, but they are stripped from Git archived through .gitattributes. In case this was not just a coincidence and such stripping is common for php projects, it would be great if there was a way to grab those test cases anyhow and execute them. I have not been able to find a way yet.

Nearly all the php-* packages are affected by this common terrible practice. You have to use a git snapshot. Please see any package
which have a makesrc.sh or %{name}-get-sources.sh script.

Ex:

https://src.fedoraproject.org/rpms/php-laminas-escaper/blob/rawhide/f/makesrc.sh

And

https://src.fedoraproject.org/rpms/php-laminas-escaper/blob/rawhide/f/php-laminas-escaper.spec#_118


I also wonder if something like %py3_check_import [4] would be useful for cases where there are no real tests to run? The idea there is to run a program that imports the library, but does not do anything, just to catch those cases where the import itself fails, rendering the package library completely unusable.

As we usually add an autoloader (recommended), at least it needs to be tested.

Ex: https://src.fedoraproject.org/rpms/php-psr-cache/blob/rawhide/f/php-psr-cache.spec#_90

This ensure one of class/interface provided by the library is found.

For compiled languages this is not so important, since compilation usually fails if things are totally broken.

Even for C extension a minimal "load" test is required, to ensure (at least) that all symbols are prooerly resolved (common error)


Remi
_______________________________________________
php-devel mailing list -- php-devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to php-devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/php-devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure




[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora KDE]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux