@@ -12,14 +12,15 @@ describe("RoutingFormResponseDenormalized", () => {
12
12
let bookingId : number ;
13
13
let responseId : number ;
14
14
const randomId = Math . floor ( Math . random ( ) * 1000000 ) ;
15
- const email = `booking-denorm-${ randomId } @example.com` ;
15
+ const email = `routing-form-response-denorm-${ randomId } @example.com` ;
16
+ const updatedEmail = `updated-${ email } ` ;
16
17
17
18
beforeEach ( async ( ) => {
18
19
// Create test user
19
20
const user = await prisma . user . create ( {
20
21
data : {
21
22
email,
22
- username : `booking -denorm-testuser-${ randomId } ` ,
23
+ username : `routing-form-response -denorm-testuser-${ randomId } ` ,
23
24
name : "Test User" ,
24
25
} ,
25
26
} ) ;
@@ -96,7 +97,7 @@ describe("RoutingFormResponseDenormalized", () => {
96
97
// Create test booking
97
98
const booking = await prisma . booking . create ( {
98
99
data : {
99
- uid : `booking -denorm-${ randomId } ` ,
100
+ uid : `routing-form-response -denorm-${ randomId } ` ,
100
101
title : "Test Booking" ,
101
102
startTime : new Date ( ) ,
102
103
endTime : new Date ( Date . now ( ) + 60 * 60 * 1000 ) ,
@@ -254,7 +255,7 @@ describe("RoutingFormResponseDenormalized", () => {
254
255
where : { id : userId } ,
255
256
data : {
256
257
name : "Updated User" ,
257
-
258
+ email : updatedEmail ,
258
259
} ,
259
260
} ) ;
260
261
@@ -263,7 +264,7 @@ describe("RoutingFormResponseDenormalized", () => {
263
264
} ) ;
264
265
265
266
expect ( denormalizedResponse . bookingUserName ) . toBe ( "Updated User" ) ;
266
- expect ( denormalizedResponse . bookingUserEmail ) . toBe ( "[email protected] " ) ;
267
+ expect ( denormalizedResponse . bookingUserEmail ) . toBe ( updatedEmail ) ;
267
268
} ) ;
268
269
269
270
it ( "should update denormalized entry when booking is updated" , async ( ) => {
@@ -636,7 +637,7 @@ describe("RoutingFormResponseDenormalized", () => {
636
637
// Create a booking with attendees
637
638
const booking = await prisma . booking . create ( {
638
639
data : {
639
- uid : `booking -denorm-${ Math . floor ( Math . random ( ) * 1000000 ) } ` ,
640
+ uid : `routing-form-response -denorm-${ Math . floor ( Math . random ( ) * 1000000 ) } ` ,
640
641
title : "Test Booking" ,
641
642
startTime : new Date ( ) ,
642
643
endTime : new Date ( Date . now ( ) + 60 * 60 * 1000 ) ,
0 commit comments