UNPKG

grunt-watchify

Version:
54 lines (45 loc) 1.08 kB
/* * grunt-watchify * http://github.com/amiorin/grunt-watchify * * Copyright (c) 2013 Alberto Miorin, contributors * Licensed under the MIT license. */ 'use strict'; module.exports = function(grunt) { grunt.initConfig({ clean: { tests: ['tmp'] }, nodeunit: { tests: ['test/*_test.js'] }, watchify: { basic: { src: './test/fixtures/basic/*.js', dest: 'tmp/basic.js' }, alias: { src: './test/fixtures/alias/*.js', dest: 'tmp/alias.js', options: { callback: function(b) { b.require('./test/fixtures/alias/toBeAliased.js', {expose: 'alias'}); return b; } } }, sourceMaps: { src: './test/fixtures/basic/*.js', dest: 'tmp/sourceMaps.js', options: { debug: true } } } }); grunt.loadTasks('tasks'); grunt.loadNpmTasks('grunt-contrib-clean'); grunt.loadNpmTasks('grunt-contrib-nodeunit'); grunt.registerTask('test', ['clean', 'watchify', 'nodeunit']); };