You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
jmrozanec edited this page Aug 5, 2014
·
11 revisions
On this page we describe architecture principles that should drive Cobertura development, current Cobertura architecture and the architecture we expect.
Considerations
Cobertura should work as a library:
should have an interface to expose functionality. A DSL is created for this purpose.
should be extensible. Users should be able to implement and easily use their own metrics and report formats.
must be decoupled from specific technologies to access it (ex.: Ant). Those technologies should use Cobertura's DSL.
Cobertura responsibilities are:
perform code instrumentation, to be able to gather information about code coverage
expose code coverage information and metrics in reports
Cobertura should not care about:
code compilation
running tests
Diagrams
(currently no diagrams are available)
Cobertura DSL
Below we provide an example on how to use Cobertura DSL.
Beware! Cobertura is licensed under GNU GPL v2. If using the DSL, you should use the same license. Otherwise consider interacting via CLI.
Arguments arguments = new ArgumentsBuilder()
.setBaseDirectory(baseDir)
.setDataFile(dataFile)
.setDestinationDirectory(destDir)
.build();
new Cobertura(arguments).instrumentCode().saveProjectData();