Skip to content

Commit

Permalink
Fix missing error.culprit
Browse files Browse the repository at this point in the history
  • Loading branch information
crespocarlos committed Dec 30, 2024
1 parent 968058f commit 8beae52
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
AGENT_NAME,
AGENT_VERSION,
AT_TIMESTAMP,
ERROR_CULPRIT,
ERROR_EXCEPTION,
ERROR_GROUP_ID,
ERROR_ID,
Expand Down Expand Up @@ -82,6 +83,7 @@ export async function getErrorSampleDetails({
SPAN_ID,
AGENT_VERSION,
PROCESSOR_NAME,
ERROR_CULPRIT,
ERROR_STACK_TRACE,
ERROR_EXC_MESSAGE,
ERROR_EXC_HANDLED,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,11 @@ export async function generateData({
.transaction({ transactionName: transaction.name })
.errors(
serviceGoProdInstance
.error({ message: `Error ${index}`, type: transaction.name })
.error({
message: `Error ${index}`,
type: transaction.name,
culprit: `Error culprit ${index}`,
})
.timestamp(timestamp)
)
.duration(1000)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,10 @@ export default function ApiTest({ getService }: DeploymentAgnosticFtrProviderCon
'Error 1'
);
});

it('displays correct error culprit info', () => {
expect(errorSampleDetailsResponse.error.error.culprit).to.equal('Error culprit 1');
});
});
});

Expand Down

0 comments on commit 8beae52

Please sign in to comment.