An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 5.5% on proxy.golang.org

proxy.golang.org : github.com/thediveo/pyrotest

Package pyrotest provides a Prometheus datamodel-specific DSL for writing concise and easily readable assertions on metrics. In addition, it highly values clear and concise failure messages that are easy to understand, avoiding unnecessary and distracting matcher details (as Gomega is sometime fallible to). As a timeseries database user you don't care about the gory internal details of the Prometheus data model, you just work with “metrics” that have “labels”. Consequently, package pyrotest conceals the confusing and fussy hierarchical differentiation of the Prometheus data model into metric families that only then contain individual metrics (that is, the individual “timeseries”). A typical usage might look like this: The basic types.GomegaMatcher for matching a single or multiple metrics are: Both ContainMetrics and BeAMetric accept only the following metric-type specific matchers: Each of these specific matchers then accept the following metric property-related matchers, where these matchers often accept either a simple value or alternatively types.GomegaMatcher (allowing for much more complex assertions): This package isn't strictly necessary, as Gomega's matcher toolchest already contains everything necessary. However, just sticking to these basics requires extensive use of gomega.HaveField matchers in combination with protobuf-originating accessor functions like prommodel.MetricFamily.GetName in order to correctly deal with the level of pointer indirection used in protobuf optional fields – which the Prometheus data model likes to use basically everywhere. pyrotest brings back concise matcher design, with build-time type-safety on top.

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/thediveo/pyrotest
License: Apache-2.0
Latest release: about 2 months ago
First release: 3 months ago
Namespace: github.com/thediveo
Stars: 0 on GitHub
Forks: 0 on GitHub
See more repository details: repos.ecosyste.ms
Last synced: 15 days ago

    Loading...
    Readme
    Loading...