diff --git a/prometheus/examples_test.go b/prometheus/examples_test.go index 0344e46..4863b95 100644 --- a/prometheus/examples_test.go +++ b/prometheus/examples_test.go @@ -14,7 +14,6 @@ package prometheus_test import ( - "flag" "fmt" "math" "net/http" @@ -48,16 +47,12 @@ func ExampleGauge() { } func ExampleGaugeVec() { - binaryVersion := flag.String("binary_version", "debug", "Version of the binary: debug, canary, production.") - flag.Parse() - opsQueued := prometheus.NewGaugeVec( prometheus.GaugeOpts{ Namespace: "our_company", Subsystem: "blob_storage", Name: "ops_queued", Help: "Number of blob storage operations waiting to be processed, partitioned by user and type.", - ConstLabels: prometheus.Labels{"binary_version": *binaryVersion}, }, []string{ // Which user has requested the operation? @@ -125,14 +120,10 @@ func ExampleCounter() { } func ExampleCounterVec() { - binaryVersion := flag.String("environment", "test", "Execution environment: test, staging, production.") - flag.Parse() - httpReqs := prometheus.NewCounterVec( prometheus.CounterOpts{ Name: "http_requests_total", Help: "How many HTTP requests processed, partitioned by status code and HTTP method.", - ConstLabels: prometheus.Labels{"env": *binaryVersion}, }, []string{"code", "method"}, )