2013-05-14 10 views
5

Ho configurato il mio compito è qunit grugnito, come di seguito:Grunt qunit sta venendo a mancare

// Unit Test Configuration 
    qunit: { 
     ac: { 
      files: ['test/**/*.html'] 
     } 
    } 
    grunt.registerTask('ac', ['jshint:ac', 'qunit:ac']); 

jsHint sta funzionando benissimo.

Running "qunit:: ac" (qunit) compito Attenzione: Impossibile usare 'in' operatore per la ricerca di 'src'

risposta

7

Change files: ['test/**/*.html']-src: ['test/**/*.html'] Ma con qunit sto ottenendo errore. La proprietà files è intesa per più coppie src/dest. Vedere http://gruntjs.com/configuring-tasks#files-object-format

Ad esempio:

qunit: { 
    ac: { 
    files: [{ 
     src: ['test/**/*.html'] 
    }, { 
     src: ['test2/**/*.html'] 
    }] 
    } 
} 

Una più semplice configurazione se si desidera solo test/**/*.html sarebbe: ac

qunit: { 
    ac: ['test/**/*.html'] 
} 
+0

Ho appena cambiato: ac: [ 'test/**/*. html '] [' test/unittest/unit1/*. html '] e ora funziona. Grazie. – VKS

Problemi correlati