var fs = require('fs'),
    testResource = require('../../../test_resource'),
    compileLessFile = require('../../../../lib/compile/compile_less_file');

exports['Compile a less file'] = function (test) {
    var src = testResource.resolveMockFile('mock-less.less'),
        dest = testResource.resolveWorkFile('work-less.css');
    compileLessFile(
        src,
        dest,
        function (err) {
            test.ifError(err);
            fs.exists(dest, function (exists) {
                test.ok(exists);
                test.done();
            });
        }
    )
};