@@ -44,6 +44,7 @@ let proposal1Id: string;
4444let proposal2Id : string ;
4545let testEmailTemplate1Id : string ;
4646let testEmailTemplate2Id : string ;
47+ let statusActionsConnectionId : number ;
4748
4849context ( 'Status actions tests' , ( ) => {
4950 beforeEach ( function ( ) {
@@ -783,6 +784,7 @@ context('Status actions tests', () => {
783784 } ) . then ( ( result ) => {
784785 const connection = result . createWorkflowConnection ;
785786 if ( connection ) {
787+ statusActionsConnectionId = connection . id ;
786788 cy . setStatusChangingEventsOnConnection ( {
787789 workflowConnectionId : connection . id ,
788790 statusChangingEvents : [ PROPOSAL_EVENTS . PROPOSAL_SUBMITTED ] ,
@@ -878,6 +880,32 @@ context('Status actions tests', () => {
878880 } ) ;
879881 } ) ;
880882
883+ it ( 'User Officer should see status actions logs whose connection configuration was later removed, with replay disabled' , ( ) => {
884+ cy . addConnectionStatusActions ( {
885+ actions : [ ] ,
886+ connectionId : statusActionsConnectionId ,
887+ workflowId : initialDBData . workflows . defaultWorkflow . id ,
888+ } ) ;
889+
890+ cy . login ( 'officer' ) ;
891+ cy . visit ( '/' ) ;
892+
893+ cy . navigateToStatusActionLogsSubmenu ( 'Email' ) ;
894+
895+ cy . finishedLoading ( ) ;
896+
897+ cy . get ( '[data-cy="status-actions-logs-table"]' )
898+ . find ( 'tbody td' )
899+ . filter ( ':contains("SUCCESSFUL")' )
900+ . should ( 'have.length.greaterThan' , 0 ) ;
901+
902+ cy . get ( '[data-cy="replay_status_action_icon"]' )
903+ . first ( )
904+ . click ( { force : true } ) ;
905+
906+ cy . get ( '[data-cy="confirm-ok"]' ) . should ( 'not.exist' ) ;
907+ } ) ;
908+
881909 it ( 'User Officer should be able to replay all email status actions in a call' , ( ) => {
882910 cy . login ( 'officer' ) ;
883911 cy . visit ( '/' ) ;
0 commit comments