Skip to content

Commit

Permalink
add cli test
Browse files Browse the repository at this point in the history
  • Loading branch information
wujunze committed Mar 17, 2017
1 parent 9fc7f88 commit b7703dc
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions example/test.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php
/**
* Created by PhpStorm.
* User: wujunze
* Date: 2017/3/17
* Time: 下午2:15
*/
require_once __DIR__ . './../vendor/autoload.php';

$colors = new Wujunze\Colors();
// Test some basic printing with Colors class
echo $colors->getColoredString("Testing Colors class, this is purple string on yellow background.", "purple", "yellow") . PHP_EOL;
echo $colors->getColoredString("Testing Colors class, this is blue string on light gray background.", "blue", "light_gray") . PHP_EOL;
echo $colors->getColoredString("Testing Colors class, this is red string on black background.", "red", "black") . PHP_EOL;
echo $colors->getColoredString("Testing Colors class, this is cyan string on green background.", "cyan", "green") . PHP_EOL;
echo $colors->getColoredString("Testing Colors class, this is cyan string on default background.", "cyan") . PHP_EOL;
echo $colors->getColoredString("Testing Colors class, this is default string on cyan background.", null, "cyan") . PHP_EOL;

0 comments on commit b7703dc

Please sign in to comment.