MediaComem / comem-archidep-php-automated-tests

Sample project to write PHP automated tests

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PHP Automated Tests

Sample project to write PHP automated tests.

Requirements

Usage

Clone this repository:

$> git clone https://github.com/MediaComem/comem-archidep-php-automated-tests

Run the script:

$> cd comem-archidep-php-automated-tests

$> php file-stats.php data/rainbow.txt
File: /path/to/data/rainbow.txt
Lines: 51
Words: 255
Characters: 1284
Size: 1.25KB

$> php file-stats.php data/japanese.txt
File: /path/to/data/japanese.txt
Lines: 2
Words: 6
Characters: 12
Size: 22B

Exercice

  • Install PHPUnit.
  • Write at least one unit test per function.
  • Write an integration test for countBytes and formatBytes together.

About

Sample project to write PHP automated tests


Languages

Language:PHP 100.0%