php - Laravel phpunit quits after first test -


i have laravel installation (version 5.2.45), trying run unit tests using phpunit. below sample unit test class wrote.

<?php  use illuminate\foundation\testing\withoutmiddleware; use illuminate\foundation\testing\databasemigrations; use illuminate\foundation\testing\databasetransactions;  class logintest extends testcase {     public function setup()     {         parent::setup();          $this->withoutmiddleware();     }      /**      * @test      */     public function testloginvalidationfail()     {         $response = $this->json('post', 'api/v1/user/login', [])             ->response;          $this->assertequals(422, $response->status());     }      /**      * @test      */     public function testlogininvalidcredentialsfail()     {         $response = $this->json('post', 'api/v1/user/login', [             'device_id' => 'xxxxxxxxxxxxxxxxxxxxxxxx',             'email'     => 'abc@example.com',             'password'  => 'abc123'         ])             ->response;          $this->assertequals(400, $response->status());     }      /**      * @test      */     public function testloginsuccess()     {         $response = $this->json('post', 'api/v1/user/login', [             'device_id' => 'xxxxxxxxxxxxxxxxxxxxxxxxxx',             'email' => 'def@example.com',             'password' => '123456'         ])             ->response;          $this->assertequals(200, $response->status());     } } 

when execute test, quits after executing first test. execution results given below.

$ phpunit phpunit 4.8.36 sebastian bergmann , contributors.  . 

i have default phpunit.xml file no modifications.

can please me find can cause issue?

thank you.


Comments

Popular posts from this blog

python - Selenium remoteWebDriver (& SauceLabs) Firefox moseMoveTo action exception -

html - How to custom Bootstrap grid height? -

transpose - Maple isnt executing function but prints function term -