1616    using  Microsoft . AspNetCore . Mvc ; 
1717    using  Microsoft . Extensions . Configuration ; 
1818    using  Microsoft . Extensions . Logging ; 
19+     using  Microsoft . FeatureManagement ; 
1920    using  NUnit . Framework ; 
2021    using  System . Collections . Generic ; 
2122    using  System . Linq ; 
@@ -49,6 +50,7 @@ public class SupervisorControllerTests
4950        private  IPdfService  pdfService  =  null ! ; 
5051        private  SupervisorController  controller  =  null ! ; 
5152        private  ICourseCategoriesService  courseCategoriesService  =  null ! ; 
53+         private  IFeatureManager  featureManager  =  null ! ; 
5254
5355        [ SetUp ] 
5456        public  void  Setup ( ) 
@@ -73,6 +75,7 @@ public void Setup()
7375            candidateAssessmentDownloadFileService  =  A . Fake < ICandidateAssessmentDownloadFileService > ( ) ; 
7476            pdfService  =  A . Fake < IPdfService > ( ) ; 
7577            courseCategoriesService  =  A . Fake < ICourseCategoriesService > ( ) ; 
78+             featureManager  =  A . Fake < IFeatureManager > ( ) ; 
7679            A . CallTo ( ( )  =>  candidateAssessmentDownloadFileService . GetCandidateAssessmentDownloadFileForCentre ( A < int > . _ ,  A < int > . _ ,  A < bool > . _ ) ) 
7780                . Returns ( new  byte [ ]  {  } ) ; 
7881
@@ -108,7 +111,8 @@ public void Setup()
108111               candidateAssessmentDownloadFileService , 
109112               clockUtility , 
110113               pdfService , 
111-                courseCategoriesService 
114+                courseCategoriesService , 
115+                featureManager 
112116           ) ; 
113117            controller . ControllerContext  =  new  ControllerContext 
114118            {  HttpContext  =  new  DefaultHttpContext  {  User  =  user  }  } ; 
@@ -140,7 +144,8 @@ public void ExportCandidateAssessment_should_return_file_object_with_file_name_i
140144                   candidateAssessmentDownloadFileService , 
141145                   clockUtility , 
142146                   pdfService , 
143-                    courseCategoriesService 
147+                    courseCategoriesService , 
148+                    featureManager 
144149               ) ; 
145150            string  expectedFileName  =  $ "{ ( ( selfAssessmentName . Length  >  30 )  ?  selfAssessmentName . Substring ( 0 ,  30 )  :  selfAssessmentName ) }  - { delegateName }  - { clockUtility . UtcNow : yyyy-MM-dd} .xlsx"; 
146151
0 commit comments