Z
Z
ZaurK2018-05-13 14:33:26
PHPUnit
ZaurK, 2018-05-13 14:33:26

Why am I getting this when checking phpunit version?

Good day! I install phpunit via composer
composer require --dev phpunit/phpunit
everything is downloaded, but when I try to check the version of php vendor/bin/phpunit --version I get

dir=$(cd "${0%[/\\]*}" > /dev/null; cd "../phpunit/phpunit" && pwd)

if [ -d /proc/cygdrive ] && ; then
   # We are in Cgywin using Windows php, so the path must be translated
   dir=$(cygpath -m "$dir");
fi

"${dir}/phpunit" "[email protected]"

what is the content of /vendor/bin/phpunit. Why is it so, what am I doing wrong?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
poul_kg, 2018-05-15
@poul_kg

try with "vendor/phpunit/phpunit/phpunit --version", if it works, then run it. I have earned. Had the same problem.

D
daniel_wesson, 2020-10-30
@daniel_wesson

This is a binary file, you need to run it without a PHP interpreter:
vendor/bin/phpunit --version
It will pull everything up by itself

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question