Adjusting the line feeds if they're windows based (\r\n) to \n.

This commit is contained in:
Robert Law
2012-07-29 23:23:53 -07:00
committed by Luke Page
parent 63821cdbe6
commit fc55458915

View File

@@ -24,6 +24,7 @@ fs.readdirSync('test/less').forEach(function (file) {
fs.readFile(path.join('test/css', name) + '.css', 'utf-8', function (e, css) {
sys.print("- " + name + ": ")
css = css && css.replace(/\r\n/g, '\n');
if (less === css) { sys.print(stylize('OK', 'green')) }
else if (err) {
sys.print(stylize("ERROR: " + (err && err.message), 'red'));