1 20 package org.apache.cactus.framework.internal; 21 22 import java.io.IOException ; 23 import java.net.MalformedURLException ; 24 25 import junit.framework.TestCase; 26 27 import org.apache.cactus.framework.internal.orchestrator.Orchestrator; 28 import org.apache.cactus.framework.internal.orchestrator.OrchestratorClient; 29 import org.codehaus.aspectwerkz.attribdef.aspect.Aspect; 30 31 public class ClientManager extends Aspect 32 { 33 private OrchestratorClient orchestratorClient; 34 35 public ClientManager() 36 { 37 this.orchestratorClient = new OrchestratorClient(); 38 } 39 40 public void initialize() throws Throwable 41 { 42 Orchestrator orchestrator = new Orchestrator(7777); 45 orchestrator.start(); 46 } 47 48 public void prepareTest(TestCase testCase) 49 throws MalformedURLException , IOException 50 { 51 String name = testCase.getName(); 52 this.orchestratorClient.setTest(name); 53 } 54 55 } 56 | Popular Tags |