01: /*
02: * Copyright 2005-2007 The Kuali Foundation.
03: *
04: *
05: * Licensed under the Educational Community License, Version 1.0 (the "License");
06: * you may not use this file except in compliance with the License.
07: * You may obtain a copy of the License at
08: *
09: * http://www.opensource.org/licenses/ecl1.php
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */
17: package edu.iu.uis.eden.test.runners;
18:
19: import java.lang.reflect.InvocationTargetException;
20: import java.lang.reflect.Method;
21:
22: import org.junit.internal.runners.TestMethodRunner;
23: import org.junit.runner.Description;
24: import org.junit.runner.notification.RunNotifier;
25:
26: public class RemotableTestMethodRunner extends TestMethodRunner {
27:
28: private String remotingProtocol;
29:
30: public RemotableTestMethodRunner(Object test, Method method,
31: RunNotifier notifier, Description description,
32: String remotingProtocol) {
33: super (test, method, notifier, description);
34: this .remotingProtocol = remotingProtocol;
35: }
36:
37: @Override
38: protected void executeMethodBody() throws IllegalAccessException,
39: InvocationTargetException {
40: throw new UnsupportedOperationException(
41: "setUpWebservices not currently supported");
42: // try {
43: // //duplicated in WorkflowTestCase
44: // Core.getCurrentContextConfig().overrideProperty(Config.CLIENT_PROTOCOL, EdenConstants.WEBSERVICE_CLIENT_PROTOCOL);
45: // Core.getCurrentContextConfig().overrideProperty("workflowutility.javaservice.endpoint", "http://localhost:9912/en-test/remoting/%7BKEW%7DWorkflowUtilityService");
46: // Core.getCurrentContextConfig().overrideProperty("workflowdocument.javaservice.endpoint", "http://localhost:9912/en-test/remoting/%7BKEW%7DWorkflowDocumentActionsService");
47: // Core.getCurrentContextConfig().overrideProperty("secure.workflowdocument.javaservice.endpoint", "true");
48: // Core.getCurrentContextConfig().overrideProperty("secure.workflowutility.javaservice.endpoint", "true");
49: // KSBConfigurer ksbConfigurer = new KSBConfigurer();
50: // ksbConfigurer.start();
51: // } catch (Exception e) {
52: // if (e instanceof RuntimeException) {
53: // throw (RuntimeException)e;
54: // }
55: // throw new RuntimeException("Failed to start the ksb configurer to run the remotable test.", e);
56: // }
57: // super.executeMethodBody();
58: }
59:
60: }
|