11import { startMoneyRequest } from '@libs/actions/IOU' ;
22import { navigateToQuickAction } from '@libs/actions/QuickActionNavigation' ;
3- import { createNewReport } from '@libs/actions/Report' ;
43import { startOutCreateTaskQuickAction } from '@libs/actions/Task' ;
54import { generateReportID } from '@libs/ReportUtils' ;
65import CONST from '@src/CONST' ;
@@ -22,7 +21,7 @@ describe('IOU Utils', () => {
2221
2322 it ( 'should be navigated to Manual Submit Expense' , ( ) => {
2423 // When the quick action is REQUEST_MANUAL
25- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . REQUEST_MANUAL , chatReportID : reportID } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
24+ navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . REQUEST_MANUAL , chatReportID : reportID } , ( onSelected : ( ) => void ) => {
2625 onSelected ( ) ;
2726 } ) ;
2827 // Then we should start manual submit request flow
@@ -31,7 +30,7 @@ describe('IOU Utils', () => {
3130
3231 it ( 'should be navigated to Scan receipt Split Expense' , ( ) => {
3332 // When the quick action is SPLIT_SCAN
34- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . SPLIT_SCAN , chatReportID : reportID } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
33+ navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . SPLIT_SCAN , chatReportID : reportID } , ( onSelected : ( ) => void ) => {
3534 onSelected ( ) ;
3635 } ) ;
3736 // Then we should start scan split request flow
@@ -40,7 +39,7 @@ describe('IOU Utils', () => {
4039
4140 it ( 'should be navigated to Track distance Expense' , ( ) => {
4241 // When the quick action is TRACK_DISTANCE
43- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . TRACK_DISTANCE , chatReportID : reportID } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
42+ navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . TRACK_DISTANCE , chatReportID : reportID } , ( onSelected : ( ) => void ) => {
4443 onSelected ( ) ;
4544 } ) ;
4645 // Then we should start distance track request flow
@@ -49,7 +48,7 @@ describe('IOU Utils', () => {
4948
5049 it ( 'should be navigated to Per Diem Expense' , ( ) => {
5150 // When the quick action is PER_DIEM
52- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . PER_DIEM , chatReportID : reportID } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
51+ navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . PER_DIEM , chatReportID : reportID } , ( onSelected : ( ) => void ) => {
5352 onSelected ( ) ;
5453 } ) ;
5554 // Then we should start per diem request flow
@@ -59,17 +58,9 @@ describe('IOU Utils', () => {
5958} ) ;
6059
6160describe ( 'Non IOU quickActions test:' , ( ) => {
62- const reportID = generateReportID ( ) ;
63-
6461 describe ( 'navigateToQuickAction' , ( ) => {
65- it ( 'creates new report for "createReport" quick action' , ( ) => {
66- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . CREATE_REPORT , chatReportID : reportID } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
67- onSelected ( ) ;
68- } ) ;
69- expect ( createNewReport ) . toHaveBeenCalled ( ) ;
70- } ) ;
7162 it ( 'starts create task flow for "assignTask" quick action' , ( ) => {
72- navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . ASSIGN_TASK , targetAccountID : 123 } , { accountID : 1234 } , undefined , ( onSelected : ( ) => void ) => {
63+ navigateToQuickAction ( true , { action : CONST . QUICK_ACTIONS . ASSIGN_TASK , targetAccountID : 123 } , ( onSelected : ( ) => void ) => {
7364 onSelected ( ) ;
7465 } ) ;
7566 expect ( startOutCreateTaskQuickAction ) . toHaveBeenCalled ( ) ;
0 commit comments