9

I've just installed Laravel and PHP on my new computer.

I've setup phpunit to work in :memory:

On running

phpunit

I get:

PHP Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in E:\xampp\php\pear\PHPUnit\TextUI\Command.php on line 277

Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in E:\xampp\php\pear\PHPUnit\TextUI\Command.php on line 277 PHP Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in E:\xampp\php\pear\PHPUnit\TextUI\Command.php on line 285

Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in E:\xampp\php\pear\PHPUnit\TextUI\Command.php on line 285 PHPUnit 3.7.21 by Sebastian Bergmann.

phpunit.xml environment variables are setup to:

<server name="APP_ENV" value="testing"/>
 <server name="DB_CONNECTION" value="sqlite"/>
 <server name="DB_DATABASE" value=":memory:"/>

Time: 0 seconds, Memory: 4.00Mb

No tests executed!

But I expect the test to run!

harshit
  • 339
  • 1
  • 5
  • 15
  • 1
    A simple Google [Backward Incompatible Changes PHP7.2 -> 7.3](https://www.php.net/manual/en/migration73.incompatible.php) – RiggsFolly Jun 05 '19 at 08:55
  • 14
    I had the same issue and the linked thread doesn't answer the asked question. The issue is probably that you are running the wrong version of `phpunit`. To run the version that is installed in your project, run `vendor/bin/phpunit` or `vendor/bin/phpunit.bat`. The test should then run successfully. – olivierhsta Feb 14 '20 at 23:56

0 Answers0