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

Add composer test script #336

Merged
merged 1 commit into from Oct 9, 2015

Conversation

MaxGfeller
Copy link
Contributor

Composer supports defining custom scripts. Major PHP projects started adapting this and are now all defining their own test scripts. Here are some examples:

The advantage of this is pretty obvious; you don't have to have a global phpunit/whatever setup and can just run composer test for each library that you want to start working with.

@mnapoli
Copy link
Member

mnapoli commented Oct 9, 2015

Why not :) But in that case it would be better to run vendor/bin/phpunit right (instead of using the potentially-missing global install)? Or does it look for phpunit inside vendor/bin already?

@mnapoli mnapoli added this to the 5.2 milestone Oct 9, 2015
@jdreesen
Copy link
Contributor

jdreesen commented Oct 9, 2015

Seems like it prefers installs in vendor/bin by adding it to the PATH: composer/composer@cec1627#diff-b2f91f0223a25c1d2dc7fff236c4dfa4R57

@mnapoli
Copy link
Member

mnapoli commented Oct 9, 2015

👍 awesome

mnapoli added a commit that referenced this pull request Oct 9, 2015
@mnapoli mnapoli merged commit 8bbe3b4 into PHP-DI:master Oct 9, 2015
@MaxGfeller
Copy link
Contributor Author

Yep, the cool thing is that 'composer run-script' adds 'vendor/bin' to the $PATH.

Thanks for merging!

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

Successfully merging this pull request may close these issues.

None yet

3 participants