Domain\Billet\Http\BilletControllerTest::test_update_by_put PHP Метод

test_update_by_put() публичный Метод

public test_update_by_put ( )
    public function test_update_by_put()
    {
        $billet = factory(Billet::class)->create();
        $data = ['amount' => 100, 'refer' => $billet->refer, 'student_id' => $billet->student_id];
        $return = $this->put('api/v1/billet/' . $billet->id, $data);
        $this->seeStatusCode(200);
        $this->seeJson(['amount' => 100]);
        $this->assertInstanceOf(Billet::class, $return->response->original);
        $this->seeInDatabase('billets', ['id' => $return->response->original->id]);
    }