@@ -208,7 +208,7 @@ void armApiBaseClient_Returns200Success_ShouldSucceed(String suffix,
208208    }
209209
210210    @ Test 
211-     void  downloadProduction_serverReturns200Success_ShouldSucceed () throws  IOException  {
211+     void  downloadProduction_Returns200Success_ShouldSucceed () throws  IOException  {
212212        String  url  = "downloadProduction/1234/false" ;
213213        String  suffix  = "downloadProduction" ;
214214        stubFor (
@@ -232,7 +232,7 @@ void downloadProduction_serverReturns200Success_ShouldSucceed() throws IOExcepti
232232    }
233233
234234    @ Test 
235-     void  getRecordManagementMatter_ShouldSucceedIfServerReturns200Success_WithEmptyRequest () throws  Exception  {
235+     void  getRecordManagementMatter_ShouldSucceed_IfServerReturns200Success_WithEmptyRequest () throws  Exception  {
236236        // Given 
237237        var  bearerAuth  = "Bearer some-token" ;
238238        EmptyRpoRequest  request  = EmptyRpoRequest .builder ().build ();
@@ -256,6 +256,49 @@ void getRecordManagementMatter_ShouldSucceedIfServerReturns200Success_WithEmptyR
256256        );
257257    }
258258
259+     @ Test 
260+     void  createExportBasedOnSearchResultsTable_ShouldSucceed_WithFullRequest () throws  Exception  {
261+         // Given 
262+         var  bearerAuth  = "Bearer some-token" ;
263+         CreateExportBasedOnSearchResultsTableRequest  request  = CreateExportBasedOnSearchResultsTableRequest .builder ()
264+             .core ("some-core" )
265+             .formFields ("some-form-fields" )
266+             .searchId ("some-search-id" )
267+             .searchitemsCount (1 )
268+             .headerColumns (
269+                 List .of (CreateExportBasedOnSearchResultsTableRequest .HeaderColumn .builder ()
270+                             .masterIndexField ("some-master-index-field" )
271+                             .displayName ("some-display-name" )
272+                             .propertyName ("some-property-name" )
273+                             .propertyType ("some-property-type" )
274+                             .isMasked (true )
275+                             .build ())
276+             )
277+             .productionName ("some-production-name" )
278+             .storageAccountId ("some-storage-account-id" )
279+             .onlyForCurrentUser (Boolean .FALSE )
280+             .exportType (32 )
281+             .build ();
282+ 
283+         stubFor (
284+             WireMock .post (urlEqualTo ("/v1/CreateExportBasedOnSearchResultsTable" ))
285+                 .willReturn (
286+                     aResponse ()
287+                         .withHeader ("Content-type" , "application/json" )
288+                         .withBody (TestUtils .getContentsFromFile (MOCK_RESPONSE_DIRECTORY  + "CreateExportBasedOnSearchResultsTable.json" ))
289+                         .withStatus (200 )));
290+ 
291+         // When 
292+         armApiBaseClient .createExportBasedOnSearchResultsTable (bearerAuth , request );
293+ 
294+         // Then 
295+         verify (postRequestedFor (urlEqualTo ("/v1/CreateExportBasedOnSearchResultsTable" ))
296+                    .withHeader (AUTHORIZATION , equalTo (bearerAuth ))
297+                    .withRequestBody (matchingJsonPath ("$.productionName" , equalTo ("some-production-name" )))
298+                    .withHeader (CONTENT_TYPE , equalTo (APPLICATION_JSON_VALUE ))
299+         );
300+     }
301+ 
259302    @ Test 
260303    void  updateMetadata_ShouldSucceed_WhenServerReturns200Success () {
261304        // Given 
0 commit comments