Skip to content

Commit

Permalink
fix line endings
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyMothra committed Nov 12, 2024
1 parent 3c11ae7 commit 8c01b21
Showing 1 changed file with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -424,18 +424,18 @@ public async Task HttpRequestMethodIsSetOnActivityAsPerSpec(string originalMetho
Assert.Equal("HTTP", activity.DisplayName);
}

Assert.Equal(expectedMethod, activity.GetTagValue(SemanticConventions.AttributeHttpRequestMethod));

Assert.Equal(expectedMethod, activity.GetTagValue(SemanticConventions.AttributeHttpRequestMethod));

#if NET9_0_OR_GREATER
if (expectedOriginalMethod != null && expectedOriginalMethod != "CUSTOM")
{
// TODO: NEED TO REVIEW THE SPEC.
// "http.request.method_original" is only set when the HTTP Method is not a standard HTTP method.

// Our implementation expects HTTP Methods to be in uppercase. "GET" is known but "Get" is unknown.
// In contrast, NET9 is case-insensitive. "GET" and "Get" are both known.
expectedOriginalMethod = null;
}
if (expectedOriginalMethod != null && expectedOriginalMethod != "CUSTOM")
{
// TODO: NEED TO REVIEW THE SPEC.
// "http.request.method_original" is only set when the HTTP Method is not a standard HTTP method.

// Our implementation expects HTTP Methods to be in uppercase. "GET" is known but "Get" is unknown.
// In contrast, NET9 is case-insensitive. "GET" and "Get" are both known.
expectedOriginalMethod = null;
}
#endif
Assert.Equal(expectedOriginalMethod, activity.GetTagValue(SemanticConventions.AttributeHttpRequestMethodOriginal));
}
Expand Down

0 comments on commit 8c01b21

Please sign in to comment.