PHP Classes

File: README.md

Recommend this page to a friend!
  Classes of Okanlawon Anuoluwapo   PHP Unit Testing Sample   README.md   Download  
File: README.md
Role: Documentation
Content type: text/markdown
Description: Documentation
Class: PHP Unit Testing Sample
Show how to test a class using PHPUnit
Author: By
Last change:
Date: 3 months ago
Size: 335 bytes
 

Contents

Class file image Download

Test app sample

Writing php unit testing with phpunit

Run composer require to install all missing dependencies

Then, to test: run below line in terminal specifying the file-path or directory name:

    ./vendor/bin/phpunit

Example:

    ./vendor/bin/phpunit tests
    ./vendor/bin/phpunit tests/UserTest.php