0

このガイドに従って、js テストから junit 出力を生成しています。

https://github.com/sbrandwoo/grunt-qunit-junit

grunt-qunit-junit をローカル テスト プロジェクトにインストールしました。

npm install grunt-contrib-qunit --save-dev

そして、これは私の Gruntfile.js です:

module.exports = function(grunt) {
    "use:strict";
    grunt.initConfig({
        pkg: grunt.file.readJSON('package.json'),
        qunit_junit: {
            options: {

            },
            all: ["all_tests.html"]         
        },
    })  
    grunt.loadNpmTasks('grunt-qunit-junit');        
};

whereall_tests.htmlは同じディレクトリにあり、すべての *test.js ファイルを一覧表示します。しかし、私が実行すると:

user@ubuntu:~/Test$ grunt qunit_junit
Running "qunit_junit" task
>> XML reports will be written to _build/test-reports

Done, without errors.

テストが実行されないのはなぜですか (フォルダ _build/test-reports が作成されません)。

4

1 に答える 1