0

I recently downloaded a fresh setup of Laravel 5.7 and have tried running the phpunit command at the command prompt with the basic settings, but it always comes through with "No tests executed"

command prompt response

Yet it has default tests that should run. Below is the snapshot of the folder setup and phpunit.xml.

folder setup and phpunit.xml

What am I missing?

I am running the setup on xampp v3.2.2

Marcin Nabiałek
  • 109,655
  • 42
  • 258
  • 291

1 Answers1

3

Looking at your command line it seems as you used very old PhpUnit so probably you use globally installed PhpUnit. Instead you should rather run

vendor\bin\phpunit.bat

to run PhpUnit that is installed for current project and it should use phpunit.xml without any problem

Marcin Nabiałek
  • 109,655
  • 42
  • 258
  • 291
  • Thank you @Marcin. It worked like a charm. Is there a way to have the original arrangement work? Do I always have to use `vendor\bin\phpunit.bat` – Samson Rwakabuguli Dec 10 '18 at 14:59
  • @SamsonRwakabuguli You can probably create some alias using https://stackoverflow.com/questions/20530996/aliases-in-windows-command-prompt – Marcin Nabiałek Dec 10 '18 at 15:58