ShingoMaeda's avatar

How to efficiently know where one method is tested.

How to know where one method is tested efficiently.

The project I'm joining in is on operation phase.So my task is to update existing codes. In this situation I often want to know where this method is tested.

when I run test like php artisan test I want feedbacks like

this method is tested by 
project/tests/Feature/... 
and project/tests/Unit/...

One solution for this is ... Put dd() within the method

Run php artisan test then test will stop where this method is tested (and I can know where).

Comment out the test method. Run php artisan test

Repeat above.

But this seems inefficient. Any ideas? Thanks.

0 likes
2 replies
bugsysha's avatar

There is no way for you to know since in feature tests something else might trigger a specific method.

ShingoMaeda's avatar

Thanks for your reply! hmm... It can’t be helped.

Please or to participate in this conversation.