<commit_before>/**
 * Created by <NAME>
 * <EMAIL>
 * 18/03/2015.
 */

var functime = require('../funcTime');
var should = require('should');

describe('main', function () {
    it('should attach base functions to wrapped method', function (done) {
        function test() {
            // Note this is the actual callback, so assertions go here:
            should.exist(test.$execTime);
            should.exist(test.$execTimeAvg);
            should.exist(test.$execTimeMax);
            should.exist(test.$execTimeMin);
            should.exist(test.$execCount);
            should.exist(test.$label);
            done();
        }

        test = test.time("Time to test");
        test();
    });

    it('should use function name as label for function', function (done) {
        function test() {
            // Note this is the actual callback, so assertions go here:
            should.exist(test.$label);
            test.$label.should.equal("test");<commit_msg>renamed tests from 'main' to 'functime'<commit_after>/**
 * Created by <NAME>
 * <EMAIL>
 * 18/03/2015.
 */

var functime = require('../funcTime');
var should = require('should');

describe('functime', function () {
    it('should attach base functions to wrapped method', function (done) {
        function test() {
            // Note this is the actual callback, so assertions go here:
            should.exist(test.$execTime);
            should.exist(test.$execTimeAvg);
            should.exist(test.$execTimeMax);
            should.exist(test.$execTimeMin);
            should.exist(test.$execCount);
            should.exist(test.$label);
            done();
        }

        test = test.time("Time to test");
        test();
    });

    it('should use function name as label for function', function (done) {
        function test() {
            // Note this is the actual callback, so assertions go here:
            should.exist(test.$label);
            test.$label.should.equal("test");
{'fraction_non_alphanumeric': 0.1396761133603239, 'fraction_numerical': 0.008097165991902834, 'mean_word_length': 2.168269230769231, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '2676482', 'n_tokens_mistral': 549, 'n_tokens_neox': 526, 'n_words': 146}