@Test public void testRunThrowsNumberFormatException() throws Throwable { Configuration cfg = new SimpleConfiguration(); DailyTaskAdaptor dailyTaskAdaptor = new DailyTaskAdaptor(); dailyTaskAdaptor.setState(2); dailyTaskAdaptor.setConfiguration(cfg); try { dailyTaskAdaptor.run(); fail("Expected NumberFormatException to be thrown"); } catch (NumberFormatException ex) { assertEquals("For input string: \":0\"", ex.getMessage(), "ex.getMessage()"); assertSame(cfg, dailyTaskAdaptor.getConfiguration(), "dailyTaskAdaptor.getConfiguration()"); } }
public void run () { while (running()) { waitUntilStartTime(); if (running()) { Thread taskThread = new Thread(task); taskThread.setDaemon (true); taskThread.start(); ISOUtil.sleep (1000); } } }
DailyTaskAdaptor extends QBeanSupport implements Runnable { public void run () { while (running()) { waitUntilStartTime(); if (running()) { Thread taskThread = new Thread(task); taskThread.setDaemon (true); taskThread.start(); ISOUtil.sleep (1000); } } } }
DailyTaskAdaptor extends QBeanSupport implements Runnable { public void run () { while (running()) { waitUntilStartTime(); if (running()) { Thread taskThread = new Thread(task); taskThread.setDaemon (true); taskThread.start(); ISOUtil.sleep (1000); } } } DailyTaskAdaptor(); }
DailyTaskAdaptor extends QBeanSupport implements Runnable { public void run () { while (running()) { waitUntilStartTime(); if (running()) { Thread taskThread = new Thread(task); taskThread.setDaemon (true); taskThread.start(); ISOUtil.sleep (1000); } } } DailyTaskAdaptor(); void run(); Date getWhen(); }
DailyTaskAdaptor extends QBeanSupport implements Runnable { public void run () { while (running()) { waitUntilStartTime(); if (running()) { Thread taskThread = new Thread(task); taskThread.setDaemon (true); taskThread.start(); ISOUtil.sleep (1000); } } } DailyTaskAdaptor(); void run(); Date getWhen();  }