inpsyde / modularity

A PSR-11 implementation for WordPress Plugins, Themes or Libraries.
https://inpsyde.github.io/modularity/
GNU General Public License v2.0
46 stars 4 forks source link

Add support for PSR-11 v2, and abandon 1.0 #25

Closed gmazzap closed 1 year ago

gmazzap commented 1 year ago

Please check if the PR fulfills these requirements

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)

Fix.

What is the current behavior? (You can also link to an open issue here)

Depending on the dependencies graph, type error might occur.

See #24

What is the new behavior (if this is a feature change)?

--

Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)

No.

Other information:

The PR contains two commits.

In the first commit, I fix the issue:

In the second, I extended the unit tests workflow matrix to include all possible combinations of PHP and PSR-11 versions. Because that means a lot of combinations, I wanted to optimize the speed, so I removed X-Debug from all the combinations but one, where we generate coverage for tests. Because that created a pretty complex workflow, I placed it in a separate workflow file for readability.

Unfortunately, on the master branch, the action workflow is not enabled for pull requests, so we can only see the check run after the merge. This PR will also fix that inconvenient, so next time we can run the actions on PRs.