<commit_before>/*jshint node: true, camelcase: false */


module.exports = function (grunt) {
	'use strict';

	grunt.loadNpmTasks('grunt-contrib-watch');
	grunt.loadNpmTasks('grunt-contrib-concat');
	grunt.loadNpmTasks('grunt-contrib-connect');
	grunt.loadNpmTasks('grunt-contrib-uglify');
	grunt.loadNpmTasks('grunt-blanket-mocha');
	grunt.loadTasks('build/tasks');

	grunt.initConfig({
		pkg: grunt.file.readJSON('package.json'),

		watch: {
			files: ['<%= concat.lib.src %>', 'test/**/*'],
			tasks: ['fixture', 'build']
		},
		concat: {
			lib: {
				src: [
					'lib/intro.stub',
					'bower_components/node-uuid/uuid.js',
					'lib/index.js',
					'lib/*/index.js',
					'lib/**/*.js',
					'lib/export.js',
					'lib/outro.stub'
				],
				dest: 'dist/dqre.js'
			},
			options: {
				process: true
			}
		},
		uglify: {
			lib: {
				files: [{
					src: ['<%= concat.lib.dest %>'],
					dest: 'dist/dqre.min.js'
				}]
			}
		},
		connect: {
			test: {
				options: {
					hostname: '0.0.0.0',
					port: 9876,
					base: ['.']
				}
			}
		},
		fixture: {
			unit: {
				src: '<%= concat.lib.src %>',
				dest: 'test/unit/index.html',
				options: {
					fixture: 'test/unit/runner.tmpl',
					testCwd: 'test/unit'
				}
			},
			integration: {
				src: '<%= concat.lib.dest %>',
				dest: 'test/integration/index.html',
				options: {
					fixture: 'test/integration/runner.tmpl',
					testCwd: 'test/integration'
				}
			}
		},
		blanket_mocha: {
			source: {
				options: {
					urls: [
						'http://localhost:9876/test/unit',
						'http://localhost:9876/test/integration'
					],
					reporter: grunt.option("reporter") || (process.env.XUNIT_FILE ? 'xunit-file' : 'Spec'),
					timeout: 10000,
					threshold: 90
				}
			}
		}
	});

	grunt.registerTask('server', ['fixture', 'connect:test:keepalive']);
	grunt.registerTask('test', ['fixture']);
	grunt.registerTask('build', ['concat', 'uglify']);
	grunt.registerTask('default', ['build']);
	grunt.registerTask('runtests', ['fixture', 'connect:test', 'blanket_mocha']);
};<commit_msg>Overwrite "test" target instead of inventing a new one<commit_after>/*jshint node: true, camelcase: false */


module.exports = function (grunt) {
	'use strict';

	grunt.loadNpmTasks('grunt-contrib-watch');
	grunt.loadNpmTasks('grunt-contrib-concat');
	grunt.loadNpmTasks('grunt-contrib-connect');
	grunt.loadNpmTasks('grunt-contrib-uglify');
	grunt.loadNpmTasks('grunt-blanket-mocha');
	grunt.loadTasks('build/tasks');

	grunt.initConfig({
		pkg: grunt.file.readJSON('package.json'),

		watch: {
			files: ['<%= concat.lib.src %>', 'test/**/*'],
			tasks: ['fixture', 'build']
		},
		concat: {
			lib: {
				src: [
					'lib/intro.stub',
					'bower_components/node-uuid/uuid.js',
					'lib/index.js',
					'lib/*/index.js',
					'lib/**/*.js',
					'lib/export.js',
					'lib/outro.stub'
				],
				dest: 'dist/dqre.js'
			},
			options: {
				process: true
			}
		},
		uglify: {
			lib: {
				files: [{
					src: ['<%= concat.lib.dest %>'],
					dest: 'dist/dqre.min.js'
				}]
			}
		},
		connect: {
			test: {
				options: {
					hostname: '0.0.0.0',
					port: 9876,
					base: ['.']
				}
			}
		},
		fixture: {
			unit: {
				src: '<%= concat.lib.src %>',
				dest: 'test/unit/index.html',
				options: {
					fixture: 'test/unit/runner.tmpl',
					testCwd: 'test/unit'
				}
			},
			integration: {
				src: '<%= concat.lib.dest %>',
				dest: 'test/integration/index.html',
				options: {
					fixture: 'test/integration/runner.tmpl',
					testCwd: 'test/integration'
				}
			}
		},
		blanket_mocha: {
			source: {
				options: {
					urls: [
						'http://localhost:9876/test/unit',
						'http://localhost:9876/test/integration'
					],
					reporter: grunt.option("reporter") || (process.env.XUNIT_FILE ? 'xunit-file' : 'Spec'),
					timeout: 10000,
					threshold: 90
				}
			}
		}
	});

	grunt.registerTask('server', ['fixture', 'connect:test:keepalive']);
	grunt.registerTask('test', ['fixture', 'connect:test', 'blanket_mocha']);
	grunt.registerTask('build', ['concat', 'uglify']);
	grunt.registerTask('default', ['build']);
};
{'fraction_non_alphanumeric': 0.20868928484256774, 'fraction_numerical': 0.011227727605565048, 'mean_word_length': 2.7979610750695088, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, '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': '6905135', 'n_tokens_mistral': 2028, 'n_tokens_neox': 1578, 'n_words': 218}