github.com/verrazzano/verrazzano@v1.7.1/tests/e2e/pkg/test/framework/metrics/ginkgo_metrics_test.go (about)

     1  // Copyright (c) 2021, 2022, Oracle and/or its affiliates.
     2  // Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl.
     3  
     4  package metrics_test
     5  
     6  import (
     7  	"fmt"
     8  
     9  	"github.com/verrazzano/verrazzano/tests/e2e/pkg/test/framework"
    10  	"github.com/verrazzano/verrazzano/tests/e2e/pkg/test/framework/metrics"
    11  )
    12  
    13  var t = framework.NewTestFramework("metrics_test")
    14  
    15  var _ = t.Describe("Logger", func() {
    16  	// Setup the Suite
    17  
    18  	_ = t.AfterEach(func() {})
    19  
    20  	t.It("Should do a thing", func() {
    21  		fmt.Println("Ran a test!")
    22  		// Emits a metric with key(foo), value(bar)
    23  		metrics.Emit(t.Metrics.With("foo", "bar"))
    24  
    25  	})
    26  
    27  	t.It("Should do another thing", func() {
    28  		fmt.Println("Second test!")
    29  
    30  	})
    31  })