reports

package module
v0.0.0-...-cff60db Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2024 License: Apache-2.0 Imports: 21 Imported by: 0

README

SDK Feature Report Generator

This tool reads junit XML reports from different SDKs and generates an HTML report showing which SDKs support which features.

Current Status

./cmd/build-html will iterate over the repos listed in sdk.go and download the most recent junit artifact. It will read all junit results from it and produce a report to _site/index.html

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotSupported = errors.New("test not supported by this SDK")
)
View Source
var (
	SDKs = []SDKMeta{
		{
			Name:         "web5-js",
			Repo:         "cyware/web5-js",
			ArtifactName: "junit-results",
			FeatureRegex: regexp.MustCompile(`Web5TestVectors(\w+)`),
			VectorRegex:  regexp.MustCompile(`\w+ \w+ (\w+)`),
			VectorPath:   "test-vectors",
		},
		{
			Name:         "web5-kt",
			Repo:         "cyware/web5-kt",
			ArtifactName: "test-results",
			FeatureRegex: regexp.MustCompile(`web5\.sdk\.\w+.Web5TestVectors(\w+)`),
			VectorRegex:  regexp.MustCompile(`(\w+)\(\)`),
			VectorPath:   "test-vectors",
		},
	}
)

Functions

func CleanupGitAuth

func CleanupGitAuth() error

func ConfigureGitAuth

func ConfigureGitAuth() error

func SyncSDK

func SyncSDK(sdk SDKMeta) error

func WriteHTML

func WriteHTML(reports []Report, filename string) error

Types

type Report

type Report struct {
	SDK     SDKMeta
	Results map[string]map[string]Result
}

func GetAllReports

func GetAllReports() ([]Report, error)

func (Report) IsPassing

func (r Report) IsPassing() bool

type Result

type Result struct {
	Exists bool
	Errors []error
	Time   time.Duration
}

func (Result) GetEmoji

func (r Result) GetEmoji() string

func (Result) GetEmojiAriaLabel

func (r Result) GetEmojiAriaLabel() string

func (Result) IsSkipped

func (r Result) IsSkipped() bool

type SDKMeta

type SDKMeta struct {
	Name         string
	Repo         string
	ArtifactName string
	FeatureRegex *regexp.Regexp
	VectorRegex  *regexp.Regexp
	VectorPath   string
}

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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