### Question:
XmlValidationDelegate implements RequestDelegationHandler { protected void validateRequiredServiceParameter(XmlObject requestDocument) throws OwsException { XmlCursor xmlCursor = requestDocument.newCursor(); xmlCursor.toFirstChild(); String serviceParameter = "service"; if (moveToAttribute(xmlCursor, serviceParameter)) { validateServiceParameter(xmlCursor.getTextValue()); } } XmlValidationDelegate(XmlDelegate toDecorate); XmlObject delegate();  }### Answer:
@Test(expected = MissingParameterValueException.class) public void testMissingServiceInRequest() throws Exception { XmlObject submitDocument = getRequest(REQUEST_MISSING_SERVICE); validatingDelegate.validateRequiredServiceParameter(submitDocument); }
@Test(expected = InvalidParameterValueException.class) public void testInvalidServiceInRequest() throws Exception { XmlObject submitDocument = getRequest(REQUEST_INVALID_SERVICE); validatingDelegate.validateRequiredServiceParameter(submitDocument); }