@@ -2,7 +2,7 @@ import { expect, test } from '@playwright/test';
22import { waitForError , waitForTransaction } from '@sentry-internal/test-utils' ;
33
44test ( 'Captures an error thrown in a route handler' , async ( { baseURL, request } ) => {
5- const errorEventPromise = waitForError ( 'bun- elysia' , event => {
5+ const errorEventPromise = waitForError ( 'elysia-bun ' , event => {
66 return ! event . type && event . exception ?. values ?. [ 0 ] ?. value === 'This is an exception with id 123' ;
77 } ) ;
88
@@ -29,7 +29,7 @@ test('Captures an error thrown in a route handler', async ({ baseURL, request })
2929} ) ;
3030
3131test ( 'Error event includes request metadata' , async ( { baseURL, request } ) => {
32- const errorEventPromise = waitForError ( 'bun- elysia' , event => {
32+ const errorEventPromise = waitForError ( 'elysia-bun ' , event => {
3333 return ! event . type && event . exception ?. values ?. [ 0 ] ?. value === 'This is an exception with id 456' ;
3434 } ) ;
3535
@@ -47,7 +47,7 @@ test('Error event includes request metadata', async ({ baseURL, request }) => {
4747} ) ;
4848
4949test ( 'Does not capture errors for 4xx responses' , async ( { baseURL, request } ) => {
50- const transactionPromise = waitForTransaction ( 'bun- elysia' , transactionEvent => {
50+ const transactionPromise = waitForTransaction ( 'elysia-bun ' , transactionEvent => {
5151 return transactionEvent ?. transaction === 'GET /test-4xx' ;
5252 } ) ;
5353
@@ -59,7 +59,7 @@ test('Does not capture errors for 4xx responses', async ({ baseURL, request }) =
5959} ) ;
6060
6161test ( 'Captures errors even when status is <= 299 in error handler' , async ( { baseURL, request } ) => {
62- const errorEventPromise = waitForError ( 'bun- elysia' , event => {
62+ const errorEventPromise = waitForError ( 'elysia-bun ' , event => {
6363 return ! event . type && event . exception ?. values ?. [ 0 ] ?. value === 'Error with 200 status' ;
6464 } ) ;
6565
@@ -75,7 +75,7 @@ test('Captures errors even when status is <= 299 in error handler', async ({ bas
7575} ) ;
7676
7777test ( 'Captures POST route errors' , async ( { baseURL, request } ) => {
78- const errorEventPromise = waitForError ( 'bun- elysia' , event => {
78+ const errorEventPromise = waitForError ( 'elysia-bun ' , event => {
7979 return ! event . type && event . exception ?. values ?. [ 0 ] ?. value === 'Post error' ;
8080 } ) ;
8181
@@ -91,7 +91,7 @@ test('Captures POST route errors', async ({ baseURL, request }) => {
9191} ) ;
9292
9393test ( 'Captures thrown string errors' , async ( { baseURL, request } ) => {
94- const errorEventPromise = waitForError ( 'bun- elysia' , event => {
94+ const errorEventPromise = waitForError ( 'elysia-bun ' , event => {
9595 return ! event . type && event . exception ?. values ?. [ 0 ] ?. value === 'String error message' ;
9696 } ) ;
9797
0 commit comments