Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
generate html for mocha browser test.
JavaScript
Branch: master

release 0.3.0

latest commit 907f94d755
Fujisawa Shin authored

README.md

grunt-mocha-html

generate html for mocha browser test.

sample Gruntfile

module.exports = function(grunt) {
    grunt.initConfig({
        pkg: grunt.file.readJSON('package.json'),
        mocha_html: {
            all: {
                src   : [ 'js/lib/*.js', 'js/*.js' ],
                test  : [ 'test/*-test.js' ],
                assert : 'chai',
                checkLeaks : false,
                template: 'path/to/custom/template.html.ejs',
                html: 'path/to/output/html.html'
            }
        },
        mocha_phantomjs: {
            all: ['test/*.html']
        }
    });

    grunt.loadNpmTasks('grunt-mocha-phantomjs');
    grunt.loadNpmTasks('grunt-mocha-html');

    grunt.registerTask('test', ['mocha_html', 'mocha_phantomjs']);
    grunt.registerTask('default', ['test']);
};
Something went wrong with that request. Please try again.