通过运行
> tasks -v
编辑:如果不工作考虑增加更多的“v”可以,如tasks -vvv
,甚至tasks -V
看到所有的任务。
我明白了,例如,cover
:
This is a list of tasks defined for the current project.
It does not list the scopes the tasks are defined in; use the 'inspect' command for that.
Tasks produce values. Use the 'show' command to run the task and print the resulting value.
check Executes the tests and saves the execution data in 'jacoco.exec'.
classesToCover compiled classes (filtered by includes and excludes) that will be covered
clean Cleaning JaCoCo's output-directory.
compile Compiles sources.
console Starts the Scala interpreter with the project classes on the classpath.
consoleProject Starts the Scala interpreter with the sbt and the build definition on the classpath and useful imports.
consoleQuick Starts the Scala interpreter with the project dependencies on the classpath.
copyResources Copies resources to the output directory.
cover Executes the tests and creates a JaCoCo coverage report.
coveredSources Covered Sources.
还要注意说话是算数的开头(包装为清楚起见):
It does not list the scopes the tasks are defined in;
use the 'inspect' command for that.
导致
> inspect cover
[info] No entry for key.
[info] Description:
[info] Executes the tests and creates a JaCoCo coverage report.
[info] Delegates:
[info] *:cover
[info] {.}/*:cover
[info] */*:cover
[info] Related:
[info] jacoco:cover
所以你知道运行jacoco:cover
任务-v在pure sbt项目中显示jacoco任务,但它并不显示任何在框架项目中的作用。但谢谢你的回答 –
@Cloudtech我明白你的意思。我已经添加了有关如何在简单的游戏应用中查看的详细信息。 –