Include multiple paths
Closed this issue · 6 comments
While we can exclude
multiple paths, we can't include multiple paths since the root
option is only a single path. Would like to be able to include multiple paths.
can you please give me an use case so I can understand how it would work?
I have a project rooted at .
, and two directories I'd like to test, ./app
and ./lib
.
Presently, I can specify root: './app'
or root: './lib'
but not both.
well, istanbul expects exactly one root. the root only means that the report will follow subfolders from that point. you may want to create 2 mocha_istanbul tasks, like
mocha_istanbul:{
app: {
options: {
root: './app'
}
},
lib: {
options:{
root: './lib'
}
}
}
the src
is where it expect more than 1 folder, but I'm not aware of the consequences of doing this:
mocha_istanbul:{
app: {
src: ['./app','./lib'],
options: {
root: './app'
}
},
}
Closing this for now, if needed reopen
Hello, I have a question regarding combining tasks result into one report and I think it is linked to the question here,
You describe a task for ./app and ./lib in your example, how would you get a report combining the results from several task like this?
I see in the standard example you use the coverageFolder attribute like so:
istanbul_check_coverage: {
default: {
options: {
coverageFolder: 'coverage*', // will check both coverage folders and merge the coverage results
check: {
lines: 80,
statements: 80
}
}
}
}
but this doesn't output a new folder with the combined report.
Is there a way to do this?