Skip to content

Commit

Permalink
Fix tests failing on unexpected http response status code
Browse files Browse the repository at this point in the history
  • Loading branch information
krystofwoldrich committed Jun 27, 2023
1 parent c397a8d commit fe7330c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ test('should correctly instrument `fetch` for performance tracing', async ({ pag
url: 'http://example.com',
type: 'fetch',
'http.response_content_length': expect.any(Number),
'http.response.status_code': 200,
},
description: 'GET http://example.com',
op: 'http.client',
Expand Down
16 changes: 8 additions & 8 deletions packages/node/test/integrations/undici.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ conditionalTest({ min: 16 })('Undici integration', () => {
{
description: 'GET http://localhost:18099/',
op: 'http.client',
data: {
data: expect.objectContaining({
'http.method': 'GET',
},
}),
},
],
[
Expand All @@ -68,10 +68,10 @@ conditionalTest({ min: 16 })('Undici integration', () => {
{
description: 'GET http://localhost:18099/',
op: 'http.client',
data: {
data: expect.objectContaining({
'http.method': 'GET',
'http.query': '?foo=bar',
},
}),
},
],
[
Expand All @@ -80,9 +80,9 @@ conditionalTest({ min: 16 })('Undici integration', () => {
{ method: 'POST' },
{
description: 'POST http://localhost:18099/',
data: {
data: expect.objectContaining({
'http.method': 'POST',
},
}),
},
],
[
Expand All @@ -91,9 +91,9 @@ conditionalTest({ min: 16 })('Undici integration', () => {
{ method: 'POST' },
{
description: 'POST http://localhost:18099/',
data: {
data: expect.objectContaining({
'http.method': 'POST',
},
}),
},
],
[
Expand Down

0 comments on commit fe7330c

Please sign in to comment.