<commit_before>/**
 * grunt-strip-code
 * https://github.com/nuzzio/grunt-strip-code
 *
 * Copyright (c) 2015 <NAME>
 * Licensed under the MIT license.
 * Date: 9/13/15
 */

'use strict';

var helper = require('./helper.js').helper;

/*
 ======== A Handy Little Nodeunit Reference ========
 https://github.com/caolan/nodeunit

 Test methods:
 test.expect(numAssertions)
 test.done()
 Test assertions:
 test.ok(value, [message])
 test.equal(actual, expected, [message])
 test.notEqual(actual, expected, [message])
 test.deepEqual(actual, expected, [message])
 test.notDeepEqual(actual, expected, [message])
 test.strictEqual(actual, expected, [message])
 test.notStrictEqual(actual, expected, [message])
 test.throws(block, [error], [message])
 test.doesNotThrow(block, [error], [message])
 test.ifError(value)
 */

exports.strip_code = {
    setUp: function (done) {
        // setup here if necessary
        done();
    },
    strip_html_and_js_code: function (test) {
        test.expect(1);
        var file = 'sample.html';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(
            actual,
            expected,
            'should strip HTML debug code and JS debug code using specified blocks array'
        );

        test.done();
    },
    default_options: function (test) {
        test.expect(1);

        var file = 'default_options.js';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(actual, expected, 'should default to using "test-code" and "end-test-code" as the identifiers.');

        test.done();
    },
    start_end_options: function (test) {
        test.expect(1);

        var file = 'start_end_options.js';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(
            actual,
            expected,
            'should use the specified start and end comment identifiers.'
        );

        test.done();
    },
    pattern_options: function (test) {
        test.expect(1);
<commit_msg>Moved default test up.<commit_after>/**
 * grunt-strip-code
 * https://github.com/nuzzio/grunt-strip-code
 *
 * Copyright (c) 2015 <NAME>
 * Licensed under the MIT license.
 * Date: 9/13/15
 */

'use strict';

var helper = require('./helper.js').helper;

/*
 ======== A Handy Little Nodeunit Reference ========
 https://github.com/caolan/nodeunit

 Test methods:
 test.expect(numAssertions)
 test.done()
 Test assertions:
 test.ok(value, [message])
 test.equal(actual, expected, [message])
 test.notEqual(actual, expected, [message])
 test.deepEqual(actual, expected, [message])
 test.notDeepEqual(actual, expected, [message])
 test.strictEqual(actual, expected, [message])
 test.notStrictEqual(actual, expected, [message])
 test.throws(block, [error], [message])
 test.doesNotThrow(block, [error], [message])
 test.ifError(value)
 */

exports.strip_code = {
    setUp: function (done) {
        // setup here if necessary
        done();
    },
    default_options: function (test) {
        test.expect(1);

        var file = 'default_options.js';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(actual, expected, 'should default to using "test-code" and "end-test-code" as the identifiers.');

        test.done();
    },
    strip_html_and_js_code: function (test) {
        test.expect(1);
        var file = 'sample.html';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(
            actual,
            expected,
            'should strip HTML debug code and JS debug code using specified blocks array'
        );

        test.done();
    },
    start_end_options: function (test) {
        test.expect(1);

        var file = 'start_end_options.js';
        var actual = helper.tmpReader(file);
        var expected = helper.expectedReader(file);
        test.equal(
            actual,
            expected,
            'should use the specified start and end comment identifiers.'
        );

        test.done();
    },
    pattern_options: function (test) {
        test.expect(1);

{'fraction_non_alphanumeric': 0.136545240893067, 'fraction_numerical': 0.006110458284371328, 'mean_word_length': 2.6658053402239448, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 4, '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': '7547891', 'n_tokens_mistral': 1263, 'n_tokens_neox': 1232, 'n_words': 309}