<commit_before>'use strict';

module.exports = function (grunt) {
	
	grunt.initConfig({
		clean: {},
		
		pact: {
			default: {},
			withOptions: {
				options: {
					port: 9000,
					host: 'localhost',
					/* dir: require('path').resolve(__dirname, '../.tmp' + Math.floor(Math.random() * 1000)),*/
					cors: true,
					log: 'log.txt',
					spec: 1,
					consumer: 'consumerName',
					provider: 'providerName'
				},
				src: 'pacts/test.pact.js'
			},
			failingPactFile: {
				options: {
					port: 9000,
					host: 'localhost'
				},
				src: 'pacts/fail.pact.js'
			},
			failingPactFileForced: {
				options: {
					force: true,
					port: 9000,
					host: 'localhost'
				},
				src: 'pacts/fail.pact.js'
			}
		},
		
		// Unit tests.
		nodeunit: {
			tests: ['**/*.spec.js', '!node_modules/**/*']
		},

		wait: {
			all: {
				options: {
					delay: 3 * 1000
				}
			}
		}
	});
	
	// Actually load this plugin's task(s).
	grunt.loadTasks('tasks');
	
	// These plugins provide necessary tasks.
	grunt.loadNpmTasks('grunt-contrib-clean');
	grunt.loadNpmTasks('grunt-contrib-nodeunit');
	grunt.loadNpmTasks('grunt-wait');
	
	// Whenever the "test" task is run, first clean the "tmp" dir, then run this
	// plugin's task(s), then test the result.
	grunt.registerTask('test', ['nodeunit']);
	
	// By default, lint and run all tests.
	grunt.registerTask('default', ['test']);


	grunt.registerMultiTask('wait', 'Stop and wait.', function () {
		var options = this.options({
			delay: 0
		});
		var done = this.async();
		var timerId = 0;
		var setTicker = function(delay, call){
			clearTimeout(timerId);
			timerId = setTimeout(call, delay);
		};
		var startTime = Date.now();

		var callback = function () {
			clearTimeout(timerId);
			grunt.log.ok('Done waiting after %dms', (Date.now() - startTime));
			done();
		};

		grunt.log.writeln('Start waiting %dms', options.delay);
		setTicker(options.delay, callback);<commit_msg>removing grunt-wait task loading<commit_after>'use strict';

module.exports = function (grunt) {
	
	grunt.initConfig({
		clean: {},
		
		pact: {
			default: {},
			withOptions: {
				options: {
					port: 9000,
					host: 'localhost',
					/* dir: require('path').resolve(__dirname, '../.tmp' + Math.floor(Math.random() * 1000)),*/
					cors: true,
					log: 'log.txt',
					spec: 1,
					consumer: 'consumerName',
					provider: 'providerName'
				},
				src: 'pacts/test.pact.js'
			},
			failingPactFile: {
				options: {
					port: 9000,
					host: 'localhost'
				},
				src: 'pacts/fail.pact.js'
			},
			failingPactFileForced: {
				options: {
					force: true,
					port: 9000,
					host: 'localhost'
				},
				src: 'pacts/fail.pact.js'
			}
		},
		
		// Unit tests.
		nodeunit: {
			tests: ['**/*.spec.js', '!node_modules/**/*']
		},

		wait: {
			all: {
				options: {
					delay: 3 * 1000
				}
			}
		}
	});
	
	// Actually load this plugin's task(s).
	grunt.loadTasks('tasks');
	
	// These plugins provide necessary tasks.
	grunt.loadNpmTasks('grunt-contrib-clean');
	grunt.loadNpmTasks('grunt-contrib-nodeunit');
	
	// Whenever the "test" task is run, first clean the "tmp" dir, then run this
	// plugin's task(s), then test the result.
	grunt.registerTask('test', ['nodeunit']);
	
	// By default, lint and run all tests.
	grunt.registerTask('default', ['test']);


	grunt.registerMultiTask('wait', 'Stop and wait.', function () {
		var options = this.options({
			delay: 0
		});
		var done = this.async();
		var timerId = 0;
		var setTicker = function(delay, call){
			clearTimeout(timerId);
			timerId = setTimeout(call, delay);
		};
		var startTime = Date.now();

		var callback = function () {
			clearTimeout(timerId);
			grunt.log.ok('Done waiting after %dms', (Date.now() - startTime));
			done();
		};

		grunt.log.writeln('Start waiting %dms', options.delay);
		setTicker(options.delay, callback);
{'fraction_non_alphanumeric': 0.1737551867219917, 'fraction_numerical': 0.012448132780082987, 'mean_word_length': 2.8150346191889217, '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': '6145711', 'n_tokens_mistral': 1715, 'n_tokens_neox': 1344, 'n_words': 303}