Let's check that these actually run.
git-svn-id: https://samskivert.googlecode.com/svn/trunk@2497 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
@@ -42,21 +42,26 @@ public class RunnablesTest
|
||||
|
||||
@Test public void testWrapInstance ()
|
||||
{
|
||||
Runnables.asRunnable(this, "instanceMethod");
|
||||
Runnables.asRunnable(this, "instanceMethod").run();
|
||||
assertTrue(_ranInstance);
|
||||
}
|
||||
|
||||
@Test public void testWrapStatic ()
|
||||
{
|
||||
Runnables.asRunnable(RunnablesTest.class, "staticMethod");
|
||||
Runnables.asRunnable(RunnablesTest.class, "staticMethod").run();
|
||||
assertTrue(_ranStatic);
|
||||
}
|
||||
|
||||
protected void instanceMethod ()
|
||||
{
|
||||
// noop!
|
||||
_ranInstance = true;
|
||||
}
|
||||
|
||||
protected static void staticMethod ()
|
||||
{
|
||||
// noop!
|
||||
_ranStatic = true;
|
||||
}
|
||||
|
||||
protected boolean _ranInstance;
|
||||
protected static boolean _ranStatic;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user