]> git.aero2k.de Git - tmp/jakarta-migration.git/blob
eed72b171f39f942ba33993e9a3873aefaa01d95
[tmp/jakarta-migration.git] /
1 /**
2  * This document is a part of the source code and related artifacts
3  * for CollectionSpace, an open source collections management system
4  * for museums and related institutions:
5  *
6  * http://www.collectionspace.org
7  * http://wiki.collectionspace.org
8  *
9  * Copyright © 2009 Regents of the University of California
10  *
11  * Licensed under the Educational Community License (ECL), Version 2.0.
12  * You may not use this file except in compliance with this License.
13  *
14  * You may obtain a copy of the ECL 2.0 License at
15  * https://source.collectionspace.org/collection-space/LICENSE.txt
16  *
17  * Unless required by applicable law or agreed to in writing, software
18  * distributed under the License is distributed on an "AS IS" BASIS,
19  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20  * See the License for the specific language governing permissions and
21  * limitations under the License.
22  */
23 package org.collectionspace.services.client.test;
24
25 import java.util.ArrayList;
26 import java.util.List;
27 import javax.ws.rs.core.MediaType;
28 import javax.ws.rs.core.Response;
29
30 import org.collectionspace.services.client.CollectionSpaceClient;
31 import org.collectionspace.services.client.ContactClient;
32 import org.collectionspace.services.client.ContactClientUtils;
33 import org.collectionspace.services.contact.ContactsCommon;
34 import org.collectionspace.services.contact.ContactsCommonList;
35 import org.collectionspace.services.jaxb.AbstractCommonList;
36
37 import org.jboss.resteasy.client.ClientResponse;
38
39 import org.jboss.resteasy.plugins.providers.multipart.MultipartInput;
40 import org.jboss.resteasy.plugins.providers.multipart.MultipartOutput;
41 import org.jboss.resteasy.plugins.providers.multipart.OutputPart;
42 import org.testng.Assert;
43 import org.testng.annotations.AfterClass;
44 import org.testng.annotations.Test;
45
46 import org.slf4j.Logger;
47 import org.slf4j.LoggerFactory;
48
49 /**
50  * ContactServiceTest, carries out tests against a
51  * deployed and running Contact Service.
52  *
53  * $LastChangedRevision: 917 $
54  * $LastChangedDate: 2009-11-06 12:20:28 -0800 (Fri, 06 Nov 2009) $
55  */
56 public class ContactServiceTest extends AbstractServiceTestImpl {
57
58    private final Logger logger =
59        LoggerFactory.getLogger(ContactServiceTest.class);
60
61     // Instance variables specific to this test.
62     final String SERVICE_PATH_COMPONENT = "contacts";
63     private String knownResourceId = null;
64     private List<String> allResourceIdsCreated = new ArrayList();
65
66     /* (non-Javadoc)
67      * @see org.collectionspace.services.client.test.BaseServiceTest#getClientInstance()
68      */
69     @Override
70     protected CollectionSpaceClient getClientInstance() {
71         return new ContactClient();
72     }
73     
74     /* (non-Javadoc)
75      * @see org.collectionspace.services.client.test.BaseServiceTest#getAbstractCommonList(org.jboss.resteasy.client.ClientResponse)
76      */
77     @Override
78         protected AbstractCommonList getAbstractCommonList(
79                         ClientResponse<AbstractCommonList> response) {
80         return response.getEntity(ContactsCommonList.class);
81     }
82
83     // ---------------------------------------------------------------
84     // CRUD tests : CREATE tests
85     // ---------------------------------------------------------------
86     // Success outcomes
87     @Override
88     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class)
89     public void create(String testName) throws Exception {
90
91         // Perform setup, such as initializing the type of service request
92         // (e.g. CREATE, DELETE), its valid and expected status codes, and
93         // its associated HTTP method name (e.g. POST, DELETE).
94         setupCreate(testName);
95
96         // Submit the request to the service and store the response.
97         ContactClient client = new ContactClient();
98         String identifier = createIdentifier();
99         MultipartOutput multipart =
100             ContactClientUtils.createContactInstance(identifier, client.getCommonPartName());
101         ClientResponse<Response> res = client.create(multipart);
102
103         int statusCode = res.getStatus();
104
105         // Check the status code of the response: does it match
106         // the expected response(s)?
107         //
108         // Specifically:
109         // Does it fall within the set of valid status codes?
110         // Does it exactly match the expected status code?
111         if(logger.isDebugEnabled()){
112             logger.debug(testName + ": status = " + statusCode);
113         }
114         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
115                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
116         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
117
118         // Store the ID returned from the first resource created
119         // for additional tests below.
120         if (knownResourceId == null){
121             knownResourceId = extractId(res);
122             if (logger.isDebugEnabled()) {
123                 logger.debug(testName + ": knownResourceId=" + knownResourceId);
124             }
125         }
126
127         // Store the IDs from every resource created by tests,
128         // so they can be deleted after tests have been run.
129         allResourceIdsCreated.add(extractId(res));
130     }
131
132     @Override
133     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
134         dependsOnMethods = {"create"})
135     public void createList(String testName) throws Exception {
136         for(int i = 0; i < 3; i++){
137             create(testName);
138         }
139     }
140
141     // Failure outcomes
142     // Placeholders until the three tests below can be uncommented.
143     // See Issue CSPACE-401.
144     @Override
145     public void createWithEmptyEntityBody(String testName) throws Exception {
146     }
147
148     @Override
149     public void createWithMalformedXml(String testName) throws Exception {
150     }
151
152     @Override
153     public void createWithWrongXmlSchema(String testName) throws Exception {
154     }
155
156     /*
157     @Override
158     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
159         dependsOnMethods = {"create", "testSubmitRequest"})
160     public void createWithEmptyEntityBody(String testName) throws Exception {
161
162     // Perform setup.
163     setupCreateWithEmptyEntityBody(testName);
164
165     // Submit the request to the service and store the response.
166     String method = REQUEST_TYPE.httpMethodName();
167     String url = getServiceRootURL();
168     String mediaType = MediaType.APPLICATION_XML;
169     final String entity = "";
170     int statusCode = submitRequest(method, url, mediaType, entity);
171
172     // Check the status code of the response: does it match
173     // the expected response(s)?
174     if(logger.isDebugEnabled()){
175         logger.debug("createWithEmptyEntityBody url=" + url +
176             " status=" + statusCode);
177      }
178     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
179     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
180     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
181     }
182
183     @Override
184     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
185         dependsOnMethods = {"create", "testSubmitRequest"})
186     public void createWithMalformedXml(String testName) throws Exception {
187
188     // Perform setup.
189     setupCreateWithMalformedXml(testName);
190
191     // Submit the request to the service and store the response.
192     String method = REQUEST_TYPE.httpMethodName();
193     String url = getServiceRootURL();
194     String mediaType = MediaType.APPLICATION_XML;
195     final String entity = MALFORMED_XML_DATA; // Constant from base class.
196     int statusCode = submitRequest(method, url, mediaType, entity);
197
198     // Check the status code of the response: does it match
199     // the expected response(s)?
200     if(logger.isDebugEnabled()){
201         logger.debug(testName + ": url=" + url +
202             " status=" + statusCode);
203      }
204     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
205     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
206     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
207     }
208
209     @Override
210     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
211         dependsOnMethods = {"create", "testSubmitRequest"})
212     public void createWithWrongXmlSchema(String testName) throws Exception {
213
214     // Perform setup.
215     setupCreateWithWrongXmlSchema(testName);
216
217     // Submit the request to the service and store the response.
218     String method = REQUEST_TYPE.httpMethodName();
219     String url = getServiceRootURL();
220     String mediaType = MediaType.APPLICATION_XML;
221     final String entity = WRONG_XML_SCHEMA_DATA;
222     int statusCode = submitRequest(method, url, mediaType, entity);
223
224     // Check the status code of the response: does it match
225     // the expected response(s)?
226     if(logger.isDebugEnabled()){
227         logger.debug(testName + ": url=" + url +
228             " status=" + statusCode);
229      }
230     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
231     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
232     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
233     }
234      */
235
236     // ---------------------------------------------------------------
237     // CRUD tests : READ tests
238     // ---------------------------------------------------------------
239     // Success outcomes
240     @Override
241     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
242         dependsOnMethods = {"create"})
243     public void read(String testName) throws Exception {
244
245         // Perform setup.
246         setupRead(testName);
247
248         // Submit the request to the service and store the response.
249         ContactClient client = new ContactClient();
250         ClientResponse<MultipartInput> res = client.read(knownResourceId);
251         int statusCode = res.getStatus();
252
253         // Check the status code of the response: does it match
254         // the expected response(s)?
255         if(logger.isDebugEnabled()){
256             logger.debug(testName + ": status = " + statusCode);
257         }
258         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
259                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
260         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
261
262         MultipartInput input = (MultipartInput) res.getEntity();
263         ContactsCommon contact = (ContactsCommon) extractPart(input,
264                 client.getCommonPartName(), ContactsCommon.class);
265         Assert.assertNotNull(contact);
266     }
267
268     // Failure outcomes
269     @Override
270     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
271         dependsOnMethods = {"read"})
272     public void readNonExistent(String testName) throws Exception {
273
274         // Perform setup.
275         setupReadNonExistent(testName);
276
277         // Submit the request to the service and store the response.
278         ContactClient client = new ContactClient();
279         ClientResponse<MultipartInput> res = client.read(NON_EXISTENT_ID);
280         int statusCode = res.getStatus();
281
282         // Check the status code of the response: does it match
283         // the expected response(s)?
284         if(logger.isDebugEnabled()){
285             logger.debug(testName + ": status = " + statusCode);
286         }
287         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
288                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
289         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
290     }
291
292     // ---------------------------------------------------------------
293     // CRUD tests : READ_LIST tests
294     // ---------------------------------------------------------------
295     // Success outcomes
296     @Override
297     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
298         dependsOnMethods = {"read"})
299     public void readList(String testName) throws Exception {
300
301         // Perform setup.
302         setupReadList(testName);
303
304         // Submit the request to the service and store the response.
305         ContactClient client = new ContactClient();
306         ClientResponse<ContactsCommonList> res = client.readList();
307         ContactsCommonList list = res.getEntity();
308         int statusCode = res.getStatus();
309
310         // Check the status code of the response: does it match
311         // the expected response(s)?
312         if(logger.isDebugEnabled()){
313             logger.debug(testName + ": status = " + statusCode);
314         }
315         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
316                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
317         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
318
319         // Optionally output additional data about list members for debugging.
320         boolean iterateThroughList = false;
321         if(iterateThroughList && logger.isDebugEnabled()){
322             List<ContactsCommonList.ContactListItem> items =
323                     list.getContactListItem();
324             int i = 0;
325             for(ContactsCommonList.ContactListItem item : items){
326                 logger.debug(testName + ": list-item[" + i + "] csid=" +
327                         item.getCsid());
328                 logger.debug(testName + ": list-item[" + i + "] objectNumber=" +
329                         item.getAddressPlace());
330                 logger.debug(testName + ": list-item[" + i + "] URI=" +
331                         item.getUri());
332                 i++;
333             }
334         }
335
336     }
337
338     // Failure outcomes
339     // None at present.
340     // ---------------------------------------------------------------
341     // CRUD tests : UPDATE tests
342     // ---------------------------------------------------------------
343     // Success outcomes
344     @Override
345     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
346         dependsOnMethods = {"read"})
347     public void update(String testName) throws Exception {
348
349         // Perform setup.
350         setupUpdate(testName);
351
352         // Submit the request to the service and store the response.
353         ContactClient client = new ContactClient();
354         ClientResponse<MultipartInput> res =
355                 client.read(knownResourceId);
356         if(logger.isDebugEnabled()){
357             logger.debug(testName + ": read status = " + res.getStatus());
358         }
359         Assert.assertEquals(res.getStatus(), EXPECTED_STATUS_CODE);
360
361         if(logger.isDebugEnabled()){
362             logger.debug("got object to update with ID: " + knownResourceId);
363         }
364         MultipartInput input = (MultipartInput) res.getEntity();
365         ContactsCommon contact = (ContactsCommon) extractPart(input,
366                 client.getCommonPartName(), ContactsCommon.class);
367         Assert.assertNotNull(contact);
368
369         // Update the content of this resource.
370         contact.setAddressType("updated-" + contact.getAddressType());
371         contact.setAddressPlace("updated-" + contact.getAddressPlace());
372         contact.setEmail("updated-" + contact.getEmail());
373         if(logger.isDebugEnabled()){
374             logger.debug("to be updated object");
375             logger.debug(objectAsXmlString(contact, ContactsCommon.class));
376         }
377         // Submit the request to the service and store the response.
378         MultipartOutput output = new MultipartOutput();
379         OutputPart commonPart = output.addPart(contact, MediaType.APPLICATION_XML_TYPE);
380         commonPart.getHeaders().add("label", client.getCommonPartName());
381
382         res = client.update(knownResourceId, output);
383         int statusCode = res.getStatus();
384         // Check the status code of the response: does it match the expected response(s)?
385         if(logger.isDebugEnabled()){
386             logger.debug(testName + ": status = " + statusCode);
387         }
388         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
389                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
390         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
391
392
393         input = (MultipartInput) res.getEntity();
394         ContactsCommon updatedContact =
395                 (ContactsCommon) extractPart(input,
396                         client.getCommonPartName(), ContactsCommon.class);
397         Assert.assertNotNull(updatedContact);
398
399         Assert.assertEquals(updatedContact.getEmail(),
400                 contact.getEmail(),
401                 "Data in updated object did not match submitted data.");
402
403     }
404
405     // Failure outcomes
406     // Placeholders until the three tests below can be uncommented.
407     // See Issue CSPACE-401.
408     @Override
409     public void updateWithEmptyEntityBody(String testName) throws Exception{
410     }
411     @Override
412     public void updateWithMalformedXml(String testName) throws Exception {
413     }
414     @Override
415     public void updateWithWrongXmlSchema(String testName) throws Exception {
416     }
417
418     /*
419     @Override
420     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
421         dependsOnMethods = {"create", "update", "testSubmitRequest"})
422     public void updateWithEmptyEntityBody(String testName) throws Exception {
423
424     // Perform setup.
425     setupUpdateWithEmptyEntityBody(testName);
426
427     // Submit the request to the service and store the response.
428     String method = REQUEST_TYPE.httpMethodName();
429     String url = getResourceURL(knownResourceId);
430     String mediaType = MediaType.APPLICATION_XML;
431     final String entity = "";
432     int statusCode = submitRequest(method, url, mediaType, entity);
433
434     // Check the status code of the response: does it match
435     // the expected response(s)?
436     if(logger.isDebugEnabled()){
437         logger.debug(testName + ": url=" + url +
438             " status=" + statusCode);
439      }
440     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
441     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
442     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
443     }
444
445     @Override
446     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
447         dependsOnMethods = {"create", "update", "testSubmitRequest"})
448     public void updateWithMalformedXml(String testName) throws Exception {
449
450     // Perform setup.
451     setupUpdateWithMalformedXml(testName);
452
453     // Submit the request to the service and store the response.
454     String method = REQUEST_TYPE.httpMethodName();
455     String url = getResourceURL(knownResourceId);
456     String mediaType = MediaType.APPLICATION_XML;
457     final String entity = MALFORMED_XML_DATA;
458     int statusCode = submitRequest(method, url, mediaType, entity);
459
460     // Check the status code of the response: does it match
461     // the expected response(s)?
462     if(logger.isDebugEnabled()){
463         logger.debug(testName + ": url=" + url +
464          " status=" + statusCode);
465      }
466     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
467     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
468     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
469     }
470
471     @Override
472     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTest.class,
473         dependsOnMethods = {"create", "update", "testSubmitRequest"})
474     public void updateWithWrongXmlSchema(String testName) throws Exception {
475
476     // Perform setup.
477     setupUpdateWithWrongXmlSchema(testName);
478
479     // Submit the request to the service and store the response.
480     String method = REQUEST_TYPE.httpMethodName();
481     String url = getResourceURL(knownResourceId);
482     String mediaType = MediaType.APPLICATION_XML;
483     final String entity = WRONG_XML_SCHEMA_DATA;
484     int statusCode = submitRequest(method, url, mediaType, entity);
485
486     // Check the status code of the response: does it match
487     // the expected response(s)?
488     if(logger.isDebugEnabled()){
489         logger.debug(testName + ": url=" + url +
490         " status=" + statusCode);
491      }
492     Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
493     invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
494     Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
495     }
496      */
497
498     @Override
499     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
500         dependsOnMethods = {"update", "testSubmitRequest"})
501     public void updateNonExistent(String testName) throws Exception {
502
503         // Perform setup.
504         setupUpdateNonExistent(testName);
505
506         // Submit the request to the service and store the response.
507         // Note: The ID used in this 'create' call may be arbitrary.
508         // The only relevant ID may be the one used in update(), below.
509         ContactClient client = new ContactClient();
510         MultipartOutput multipart =
511                 ContactClientUtils.createContactInstance(NON_EXISTENT_ID, client.getCommonPartName());
512         ClientResponse<MultipartInput> res =
513                 client.update(NON_EXISTENT_ID, multipart);
514         int statusCode = res.getStatus();
515
516         // Check the status code of the response: does it match
517         // the expected response(s)?
518         if(logger.isDebugEnabled()){
519             logger.debug(testName + ": status = " + statusCode);
520         }
521         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
522                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
523         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
524     }
525
526     // ---------------------------------------------------------------
527     // CRUD tests : DELETE tests
528     // ---------------------------------------------------------------
529     // Success outcomes
530     @Override
531     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
532         dependsOnMethods = {"create", "readList", "testSubmitRequest", "update"})
533     public void delete(String testName) throws Exception {
534
535         // Perform setup.
536         setupDelete(testName);
537
538         // Submit the request to the service and store the response.
539         ContactClient client = new ContactClient();
540         ClientResponse<Response> res = client.delete(knownResourceId);
541         int statusCode = res.getStatus();
542
543         // Check the status code of the response: does it match
544         // the expected response(s)?
545         if(logger.isDebugEnabled()){
546             logger.debug(testName + ": status = " + statusCode);
547         }
548         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
549                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
550         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
551     }
552
553     // Failure outcomes
554     @Override
555     @Test(dataProvider="testName", dataProviderClass=AbstractServiceTestImpl.class,
556         dependsOnMethods = {"delete"})
557     public void deleteNonExistent(String testName) throws Exception {
558
559         // Perform setup.
560         setupDeleteNonExistent(testName);
561
562         // Submit the request to the service and store the response.
563         ContactClient client = new ContactClient();
564         ClientResponse<Response> res = client.delete(NON_EXISTENT_ID);
565         int statusCode = res.getStatus();
566
567         // Check the status code of the response: does it match
568         // the expected response(s)?
569         if(logger.isDebugEnabled()){
570             logger.debug(testName + ": status = " + statusCode);
571         }
572         Assert.assertTrue(REQUEST_TYPE.isValidStatusCode(statusCode),
573                 invalidStatusCodeMessage(REQUEST_TYPE, statusCode));
574         Assert.assertEquals(statusCode, EXPECTED_STATUS_CODE);
575     }
576
577     // ---------------------------------------------------------------
578     // Utility tests : tests of code used in tests above
579     // ---------------------------------------------------------------
580     /**
581      * Tests the code for manually submitting data that is used by several
582      * of the methods above.
583      */
584     @Test(dependsOnMethods = {"create", "read"})
585     public void testSubmitRequest() {
586
587         // Expected status code: 200 OK
588         final int EXPECTED_STATUS = Response.Status.OK.getStatusCode();
589
590         // Submit the request to the service and store the response.
591         String method = ServiceRequestType.READ.httpMethodName();
592         String url = getResourceURL(knownResourceId);
593         int statusCode = submitRequest(method, url);
594
595         // Check the status code of the response: does it match
596         // the expected response(s)?
597         if(logger.isDebugEnabled()){
598             logger.debug("testSubmitRequest: url=" + url +
599                 " status=" + statusCode);
600         }
601         Assert.assertEquals(statusCode, EXPECTED_STATUS);
602
603     }
604
605     // ---------------------------------------------------------------
606     // Cleanup of resources created during testing
607     // ---------------------------------------------------------------
608
609     /**
610      * Deletes all resources created by tests, after all tests have been run.
611      *
612      * This cleanup method will always be run, even if one or more tests fail.
613      * For this reason, it attempts to remove all resources created
614      * at any point during testing, even if some of those resources
615      * may be expected to be deleted by certain tests.
616      */
617     @AfterClass(alwaysRun=true)
618     public void cleanUp() {
619         if (logger.isDebugEnabled()) {
620             logger.debug("Cleaning up temporary resources created for testing ...");
621         }
622         ContactClient client = new ContactClient();
623         for (String resourceId : allResourceIdsCreated) {
624             // Note: Any non-success responses are ignored and not reported.
625             ClientResponse<Response> res = client.delete(resourceId);
626         }
627     }
628
629     // ---------------------------------------------------------------
630     // Utility methods used by tests above
631     // ---------------------------------------------------------------
632     @Override
633     public String getServicePathComponent() {
634         return SERVICE_PATH_COMPONENT;
635     }
636
637 }