cobertura

package
v0.0.0-...-b83e1b1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 10, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Class

type Class struct {
	XMLName xml.Name `xml:"class"`

	Filename       string         `xml:"filename,attr"`
	LinesContainer LinesContainer `xml:"lines"`
}

type ClassesContainer

type ClassesContainer struct {
	XMLName xml.Name `xml:"classes"`

	Classes []Class `xml:"class"`
}

type DefaultLoader

type DefaultLoader struct {
	// contains filtered or unexported fields
}

func NewReportLoader

func NewReportLoader(sourceDir string) *DefaultLoader

func (*DefaultLoader) Load

func (l *DefaultLoader) Load(coverageFile string) (coverage.Report, error)

type Line

type Line struct {
	XMLName xml.Name `xml:"line"`

	Number int `xml:"number,attr"`
	Hits   int `xml:"hits,attr"`
}

type LinesContainer

type LinesContainer struct {
	XMLName xml.Name `xml:"lines"`

	Lines []Line `xml:"line"`
}

type Package

type Package struct {
	XMLName xml.Name `xml:"package"`

	Name             string           `xml:"name,attr"`
	ClassesContainer ClassesContainer `xml:"classes"`
}

type PackageContainer

type PackageContainer struct {
	XMLName xml.Name `xml:"packages"`

	Packages []Package `xml:"package"`
}

type Report

type Report struct {
	XMLName xml.Name `xml:"coverage"`

	ReportSources    ReportSources    `xml:"sources"`
	PackageContainer PackageContainer `xml:"packages"`
	// contains filtered or unexported fields
}

func (*Report) GetCoverageData

func (r *Report) GetCoverageData(_ string, srcDir string, pkg string, fileName string, lineNumber int) (*domain.CoverageData, bool)

type ReportSources

type ReportSources struct {
	XMLName xml.Name `xml:"sources"`

	Sources []string `xml:"source"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL