I used phpunit to test the Laravel API. The API has return result like
{
success: true,
data: {
'attr1': 'value1',
'attr2': 'value2'
}
}
when I used:
seeJson([
'success' => true
])
it's pass, but when I used
seeJson([
'success' => true,
'data' => [
'attr1' => 'value1'
]
])
it's fail. any way to make it pass?
Please help me. thank you.