learner_here
learner_here

Reputation: 1

How to run unit testing in cakephp3?

There was pretty simple way to run unit testing in cakephp2 from browser.But how to run such tests in cakephp3 ? I read cake documentation and nothing found easily ? thanks in advance..

Upvotes: 0

Views: 1047

Answers (1)

Manohar Khadka
Manohar Khadka

Reputation: 2195

In cakephp3 i don't think there is a way to run unit testing from browser.But no worries, you can do it from command prompt.Suppose you have any function to be tested within articles model then, In command prompt, go to your project directory and just run:

phpunit tests/TestCase/Model/Table/ArticlesTableTest

and for functions of controller just run:

phpunit tests/TestCase/Controller/ArticlesControllerTest

Upvotes: 1

Related Questions