Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Laravel 5.5 dusk could not work

I make a new Laravel project:

composer create-project laravel/laravel testing_laravel
composer require laravel/dusk --dev 
php artisan serve
php artisan dusk

and then...

PHPUnit 6.3.1 by Sebastian Bergmann and contributors.

F                                                                   1 /         1 (100%)

Time: 1.12 seconds, Memory: 10.00MB

There was 1 failure:

1) Tests\Browser\ExampleTest::testBasicExample
Did not see expected text [Laravel] within element [body].
Failed asserting that false is true.

/Users/nobuhiroharada/work/laracast/testing_laravel/vendor/laravel/dusk/src/Concerns/MakesAssertions.php:274
/Users/nobuhiroharada/work/laracast/testing_laravel/vendor/laravel/dusk/src/Concerns/MakesAssertions.php:245
/Users/nobuhiroharada/work/laracast/testing_laravel/tests/Browser/ExampleTest.php:20
/Users/nobuhiroharada/work/laracast/testing_laravel/vendor/laravel/dusk/src/TestCase.php:92
/Users/nobuhiroharada/work/laracast/testing_laravel/tests/Browser/ExampleTest.php:21

FAILURES!
Tests: 1, Assertions: 1, Failures: 1.

Chrome browser is not lauching.

I am using macOS Sierra 10.12.1 on localhost.

"laravel/framework": "5.5.*",
"laravel/dusk": "^2.0"
  • Google Chrome version: 61.0.3163.100
  • ChromeDriver 2.31.488774

Thank you very much for your help.

like image 399
nobuhiroharada Avatar asked Dec 08 '22 16:12

nobuhiroharada


1 Answers

I found the solution. I didn't configure the port. It's in the .env file:

APP_URL=http://127.0.0.1

APP_URL=http://127.0.0.1:8000
like image 62
nobuhiroharada Avatar answered Dec 11 '22 11:12

nobuhiroharada