@@ -14,6 +14,9 @@ import createRandomTransaction from '../../utils/collections/transaction';
1414import getOnyxValue from '../../utils/getOnyxValue' ;
1515import waitForBatchedUpdates from '../../utils/waitForBatchedUpdates' ;
1616
17+ const RORY_EMAIL = 'rory@expensifail.com' ;
18+ const RORY_ACCOUNT_ID = 3 ;
19+
1720describe ( 'actions/IOU/BulkEdit' , ( ) => {
1821 describe ( 'updateMultipleMoneyRequests' , ( ) => {
1922 it ( 'applies expense report sign to amount updates' , ( ) => {
@@ -69,6 +72,8 @@ describe('actions/IOU/BulkEdit', () => {
6972 hash : undefined ,
7073 introSelected : undefined ,
7174 betas : undefined ,
75+ currentUserLogin : RORY_EMAIL ,
76+ currentUserAccountID : RORY_ACCOUNT_ID ,
7277 } ) ;
7378
7479 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -140,6 +145,8 @@ describe('actions/IOU/BulkEdit', () => {
140145 hash : undefined ,
141146 introSelected : undefined ,
142147 betas : undefined ,
148+ currentUserLogin : RORY_EMAIL ,
149+ currentUserAccountID : RORY_ACCOUNT_ID ,
143150 } ) ;
144151
145152 expect ( writeSpy ) . not . toHaveBeenCalled ( ) ;
@@ -200,6 +207,8 @@ describe('actions/IOU/BulkEdit', () => {
200207 hash : undefined ,
201208 introSelected : undefined ,
202209 betas : undefined ,
210+ currentUserLogin : RORY_EMAIL ,
211+ currentUserAccountID : RORY_ACCOUNT_ID ,
203212 } ) ;
204213
205214 const getOptimisticTotal = ( callIndex : number ) => {
@@ -269,6 +278,8 @@ describe('actions/IOU/BulkEdit', () => {
269278 hash : undefined ,
270279 introSelected : undefined ,
271280 betas : undefined ,
281+ currentUserLogin : RORY_EMAIL ,
282+ currentUserAccountID : RORY_ACCOUNT_ID ,
272283 } ) ;
273284
274285 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -342,6 +353,8 @@ describe('actions/IOU/BulkEdit', () => {
342353 hash : undefined ,
343354 introSelected : undefined ,
344355 betas : undefined ,
356+ currentUserLogin : RORY_EMAIL ,
357+ currentUserAccountID : RORY_ACCOUNT_ID ,
345358 } ) ;
346359
347360 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -406,6 +419,8 @@ describe('actions/IOU/BulkEdit', () => {
406419 hash : undefined ,
407420 introSelected : undefined ,
408421 betas : undefined ,
422+ currentUserLogin : RORY_EMAIL ,
423+ currentUserAccountID : RORY_ACCOUNT_ID ,
409424 } ) ;
410425
411426 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -468,6 +483,8 @@ describe('actions/IOU/BulkEdit', () => {
468483 hash : undefined ,
469484 introSelected : undefined ,
470485 betas : undefined ,
486+ currentUserLogin : RORY_EMAIL ,
487+ currentUserAccountID : RORY_ACCOUNT_ID ,
471488 } ) ;
472489
473490 expect ( writeSpy ) . toHaveBeenCalled ( ) ;
@@ -538,6 +555,8 @@ describe('actions/IOU/BulkEdit', () => {
538555 hash : undefined ,
539556 introSelected : undefined ,
540557 betas : undefined ,
558+ currentUserLogin : RORY_EMAIL ,
559+ currentUserAccountID : RORY_ACCOUNT_ID ,
541560 } ) ;
542561 await waitForBatchedUpdates ( ) ;
543562
@@ -592,6 +611,8 @@ describe('actions/IOU/BulkEdit', () => {
592611 hash : undefined ,
593612 introSelected : undefined ,
594613 betas : undefined ,
614+ currentUserLogin : RORY_EMAIL ,
615+ currentUserAccountID : RORY_ACCOUNT_ID ,
595616 } ) ;
596617 await waitForBatchedUpdates ( ) ;
597618
@@ -649,6 +670,8 @@ describe('actions/IOU/BulkEdit', () => {
649670 hash : undefined ,
650671 introSelected : undefined ,
651672 betas : undefined ,
673+ currentUserLogin : RORY_EMAIL ,
674+ currentUserAccountID : RORY_ACCOUNT_ID ,
652675 } ) ;
653676 await waitForBatchedUpdates ( ) ;
654677
@@ -713,6 +736,8 @@ describe('actions/IOU/BulkEdit', () => {
713736 hash : undefined ,
714737 introSelected : undefined ,
715738 betas : undefined ,
739+ currentUserLogin : RORY_EMAIL ,
740+ currentUserAccountID : RORY_ACCOUNT_ID ,
716741 } ) ;
717742 await waitForBatchedUpdates ( ) ;
718743
@@ -778,6 +803,8 @@ describe('actions/IOU/BulkEdit', () => {
778803 } ,
779804 introSelected : undefined ,
780805 betas : undefined ,
806+ currentUserLogin : RORY_EMAIL ,
807+ currentUserAccountID : RORY_ACCOUNT_ID ,
781808 } ) ;
782809 await waitForBatchedUpdates ( ) ;
783810
@@ -854,6 +881,8 @@ describe('actions/IOU/BulkEdit', () => {
854881 } ,
855882 introSelected : undefined ,
856883 betas : undefined ,
884+ currentUserLogin : RORY_EMAIL ,
885+ currentUserAccountID : RORY_ACCOUNT_ID ,
857886 } ) ;
858887 await waitForBatchedUpdates ( ) ;
859888
@@ -918,6 +947,8 @@ describe('actions/IOU/BulkEdit', () => {
918947 hash : undefined ,
919948 introSelected : undefined ,
920949 betas : undefined ,
950+ currentUserLogin : RORY_EMAIL ,
951+ currentUserAccountID : RORY_ACCOUNT_ID ,
921952 } ) ;
922953 await waitForBatchedUpdates ( ) ;
923954
@@ -995,6 +1026,8 @@ describe('actions/IOU/BulkEdit', () => {
9951026 hash : undefined ,
9961027 introSelected : undefined ,
9971028 betas : undefined ,
1029+ currentUserLogin : RORY_EMAIL ,
1030+ currentUserAccountID : RORY_ACCOUNT_ID ,
9981031 } ) ;
9991032 await waitForBatchedUpdates ( ) ;
10001033
@@ -1052,6 +1085,8 @@ describe('actions/IOU/BulkEdit', () => {
10521085 hash : undefined ,
10531086 introSelected : undefined ,
10541087 betas : undefined ,
1088+ currentUserLogin : RORY_EMAIL ,
1089+ currentUserAccountID : RORY_ACCOUNT_ID ,
10551090 } ) ;
10561091
10571092 // category/billable changes must be silently dropped for IOUs —
@@ -1134,6 +1169,8 @@ describe('actions/IOU/BulkEdit', () => {
11341169 allPolicies,
11351170 introSelected : undefined ,
11361171 betas : undefined ,
1172+ currentUserLogin : RORY_EMAIL ,
1173+ currentUserAccountID : RORY_ACCOUNT_ID ,
11371174 } ) ;
11381175
11391176 // Then: the optimistic transaction update should use the transaction's own policy for tax resolution.
@@ -1224,6 +1261,8 @@ describe('actions/IOU/BulkEdit', () => {
12241261 allPolicies,
12251262 introSelected : undefined ,
12261263 betas : undefined ,
1264+ currentUserLogin : RORY_EMAIL ,
1265+ currentUserAccountID : RORY_ACCOUNT_ID ,
12271266 } ) ;
12281267
12291268 // Then: buildOptimisticModifiedExpenseReportAction should receive the transaction's own policy,
@@ -1292,6 +1331,8 @@ describe('actions/IOU/BulkEdit', () => {
12921331 hash : undefined ,
12931332 introSelected : undefined ,
12941333 betas : undefined ,
1334+ currentUserLogin : RORY_EMAIL ,
1335+ currentUserAccountID : RORY_ACCOUNT_ID ,
12951336 } ) ;
12961337
12971338 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -1359,6 +1400,8 @@ describe('actions/IOU/BulkEdit', () => {
13591400 hash : undefined ,
13601401 introSelected : undefined ,
13611402 betas : undefined ,
1403+ currentUserLogin : RORY_EMAIL ,
1404+ currentUserAccountID : RORY_ACCOUNT_ID ,
13621405 } ) ;
13631406
13641407 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
@@ -1422,6 +1465,8 @@ describe('actions/IOU/BulkEdit', () => {
14221465 hash : undefined ,
14231466 introSelected : undefined ,
14241467 betas : undefined ,
1468+ currentUserLogin : RORY_EMAIL ,
1469+ currentUserAccountID : RORY_ACCOUNT_ID ,
14251470 } ) ;
14261471
14271472 const params = writeSpy . mock . calls . at ( 0 ) ?. [ 1 ] as { updates : string } ;
0 commit comments