Skip to content
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

Include phpunit and automate unit tests #39

Open
gRegorLove opened this issue Feb 9, 2023 · 0 comments
Open

Include phpunit and automate unit tests #39

gRegorLove opened this issue Feb 9, 2023 · 0 comments

Comments

@gRegorLove
Copy link
Contributor

The readme instructions to run phpunit.phar presume that you have phpunit installed already. If you don't, the unit tests won't run. It would probably be better to include phpunit under require-dev in composer.json and set up a composer script to run them.

The tests appear to be written for phpunit ~5.7 and won't run under v9+. Depending on which versions you want to list as supported (#38), it would be a good idea to set up Github Actions to run the unit tests for the supported PHP versions. If you want to support PHP 5.6 through 8.2, this polyfill makes it pretty easy to make the unit tests cross-version compatible. That's implemented on a few projects like https://github.com/microformats/php-mf2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant