You've already forked opentelemetry-go
mirror of
https://github.com/open-telemetry/opentelemetry-go.git
synced 2025-11-23 22:34:47 +02:00
Rename otel/label -> otel/attribute (#1541)
* Rename otel/label -> otel/attr Leave the imported name alone, to avoid a large diff and conflicts * Better import comment * Update CHANGELOG.md Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com> * otel/attr -> otel/attribute * Missed the changelog entry * Get rid of import renaming * Merge remaining conflicts Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com> Co-authored-by: Anthony Mirabella <a9@aneurysm9.com>
This commit is contained in:
@@ -21,7 +21,7 @@ import (
|
||||
|
||||
"github.com/google/go-cmp/cmp"
|
||||
|
||||
"go.opentelemetry.io/otel/label"
|
||||
"go.opentelemetry.io/otel/attribute"
|
||||
"go.opentelemetry.io/otel/oteltest"
|
||||
"go.opentelemetry.io/otel/propagation"
|
||||
"go.opentelemetry.io/otel/trace"
|
||||
@@ -280,7 +280,7 @@ func TestTraceStatePropagation(t *testing.T) {
|
||||
prop := propagation.TraceContext{}
|
||||
stateHeader := "tracestate"
|
||||
parentHeader := "traceparent"
|
||||
state, err := trace.TraceStateFromKeyValues(label.String("key1", "value1"), label.String("key2", "value2"))
|
||||
state, err := trace.TraceStateFromKeyValues(attribute.String("key1", "value1"), attribute.String("key2", "value2"))
|
||||
if err != nil {
|
||||
t.Fatalf("Unable to construct expected TraceState: %s", err.Error())
|
||||
}
|
||||
@@ -341,7 +341,7 @@ func TestTraceStatePropagation(t *testing.T) {
|
||||
if diff := cmp.Diff(
|
||||
trace.RemoteSpanContextFromContext(ctx),
|
||||
tt.wantSc,
|
||||
cmp.AllowUnexported(label.Value{}),
|
||||
cmp.AllowUnexported(attribute.Value{}),
|
||||
cmp.AllowUnexported(trace.TraceState{}),
|
||||
); diff != "" {
|
||||
t.Errorf("Extracted tracestate: -got +want %s", diff)
|
||||
|
||||
Reference in New Issue
Block a user