Merge pull request #8 from p0nce/master

Fix Windows unittests.
This commit is contained in:
yamadapc 2014-08-05 16:00:47 -03:00
commit 8fe0299657

View file

@ -77,27 +77,27 @@ string color(
unittest
{
import std.stdio;
import colorize.cwrite;
string ret;
ret = "This is yellow".color(fg.yellow);
writeln(ret);
cwriteln(ret);
assert(ret == "\033[33mThis is yellow\033[0m");
ret = "This is light green".color(fg.light_green);
writeln(ret);
cwriteln(ret);
assert(ret == "\033[92mThis is light green\033[0m");
ret = "This is light blue with red background".color(fg.light_blue, bg.red);
writeln(ret);
cwriteln(ret);
assert(ret == "\033[0;94;41mThis is light blue with red background\033[0m");
ret = "This is red on blue blinking".color(fg.red, bg.blue, mode.blink);
writeln(ret);
cwriteln(ret);
assert(ret == "\033[5;31;44mThis is red on blue blinking\033[0m");
ret = color("This is magenta", "magenta");
writeln(ret);
cwriteln(ret);
assert(ret == "\033[35mThis is magenta\033[0m");
}
@ -180,7 +180,7 @@ alias colorHelper color;
unittest
{
import std.stdio;
import colorize.cwrite;
string ret;
ret = "This is red on blue blinking"
@ -188,6 +188,6 @@ unittest
.background(bg.blue)
.style(mode.blink);
writeln(ret);
cwriteln(ret);
assert(ret == "\033[5m\033[44m\033[31mThis is red on blue blinking\033[0m\033[0m\033[0m");
}