Browse souce code repository at: https://github.com/jjYBdx4IL/java-evaluation/blob/master/src/test/java/tests/java/lang/reflect/dynproxy/DebugProxyTest.java
package tests.java.lang.reflect.dynproxy;

import static org.junit.Assert.assertEquals;
import org.junit.Test;

/**
 *
 * @author jjYBdx4IL
 */
public class DebugProxyTest {

    @Test
    public void test() {
        FooImpl impl = new FooImpl();
        Foo foo = (Foo) DebugProxy.newInstance(impl);
        foo.update();
        assertEquals(1, impl.testCounter);
    }
}
-------------------------------------------------------------------------------
Test set: tests.java.lang.reflect.dynproxy.DebugProxyTest
-------------------------------------------------------------------------------
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 s - in tests.java.lang.reflect.dynproxy.DebugProxyTest
test  Time elapsed: 0 s