/** * This method will only throw exceptions if some aspect * of the test's internal operation fails. */ public TestReport runImpl() throws Exception { rq = RunnableQueue.createRunnableQueue(); List l = new ArrayList(nThreads); rand = new Random(2345); // Two switch flickers to make things interesting... l.add(new SwitchFlicker()); l.add(new SwitchFlicker()); for (int i=0; i<nThreads; i++) { Runnable rqRable = new RQRable(i, rand.nextInt(50)+1); l.add(new TPRable(rq, i, rand.nextInt(4)+1, rand.nextInt(500)+1, 20, rqRable)); } synchronized (this) { ThreadPounder tp = new ThreadPounder(l); tp.start(); activeThreads = nThreads; while (activeThreads != 0) { wait(); } } System.exit(0); return null; }
updateRunnableQueue = RunnableQueue.createRunnableQueue(); runHandler = createRunHandler(); updateRunnableQueue.setRunHandler(runHandler);
updateRunnableQueue = RunnableQueue.createRunnableQueue(); runHandler = createRunHandler(); updateRunnableQueue.setRunHandler(runHandler);
updateRunnableQueue = RunnableQueue.createRunnableQueue(); runHandler = createRunHandler(); updateRunnableQueue.setRunHandler(runHandler);