Laravel 8 响应断言
2021-07-16 14:26 更新
Laravel 为你的 PHPUnit 功能测试提供了各种自定义断言方法。这些断言可以在从 json
,get
,post
,put
和 delete
测试方法返回的响应中访问:
assertCookie
assertCookieExpired
assertCookieNotExpired
assertCookieMissing
assertCreated
assertDontSee
assertDontSeeText
assertExactJson
assertForbidden
assertHeader
assertHeaderMissing
assertJson
assertJsonCount
assertJsonFragment
assertJsonMissing
assertJsonMissingExact
以上内容是否对您有帮助:
更多建议: