Sync with auto generated semantic convention constants (#428)

This commit is contained in:
Srikanth Chekuri
2021-04-20 12:07:10 +05:30
committed by GitHub
parent 308369004c
commit 8d0c150b31
94 changed files with 1141 additions and 661 deletions

View File

@ -27,6 +27,7 @@ from opentelemetry.exporter import datadog
from opentelemetry.sdk import trace
from opentelemetry.sdk.trace import Resource, sampling
from opentelemetry.sdk.util.instrumentation import InstrumentationInfo
from opentelemetry.semconv.trace import SpanAttributes
class MockDatadogSpanExporter(datadog.DatadogSpanExporter):
@ -302,8 +303,14 @@ class TestDatadogSpanExporter(unittest.TestCase):
def test_resources(self):
test_attributes = [
{},
{"http.method": "GET", "http.route": "/foo/<int:id>"},
{"http.method": "GET", "http.target": "/foo/200"},
{
SpanAttributes.HTTP_METHOD: "GET",
SpanAttributes.HTTP_ROUTE: "/foo/<int:id>",
},
{
SpanAttributes.HTTP_METHOD: "GET",
SpanAttributes.HTTP_TARGET: "/foo/200",
},
]
for index, test in enumerate(test_attributes):