<commit_before>var PATH = require('path'),
    Q = require('Q'),
    spawn = require('child_process').spawn;

/**
 * Two SVG files rendering and visually comparing with PhantomJS.
 *
 * @see http://phantomjs.org/
 * @see /lib/phantom_test.js
 *
 * @param {String} file1 file1
 * @param {String} file2 file2
 * @param {Number} width viewport width
 * @param {Number} height viewport height
 */
exports.test = function(file1, file2, width, height) {

    var compareFile = PATH.resolve(__dirname, './phantom_test.js'),
        phantom = spawn('phantomjs', [compareFile, file1, file2, width, height]),
        deferred = Q.defer();

    phantom.on('exit', function(code) {
        deferred.resolve(code);
    });

    return deferred.promise;

};<commit_msg>lib/phantom_wrapper: rename variable<commit_after>var PATH = require('path'),
    Q = require('Q'),
    spawn = require('child_process').spawn;

/**
 * Two SVG files rendering and visually comparing with PhantomJS.
 *
 * @see http://phantomjs.org/
 * @see /lib/phantom_test.js
 *
 * @param {String} file1 file1
 * @param {String} file2 file2
 * @param {Number} width viewport width
 * @param {Number} height viewport height
 */
exports.test = function(file1, file2, width, height) {

    var phantomTestFile = PATH.resolve(__dirname, './phantom_test.js'),
        phantom = spawn('phantomjs', [phantomTestFile, file1, file2, width, height]),
        deferred = Q.defer();

    phantom.on('exit', function(code) {
        deferred.resolve(code);
    });

    return deferred.promise;

};
{'fraction_non_alphanumeric': 0.15055158987670345, 'fraction_numerical': 0.010382868267358857, 'mean_word_length': 3.6167664670658684, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2321548', 'n_tokens_mistral': 511, 'n_tokens_neox': 475, 'n_words': 124}