Package honeycrm.server.test.small.dyn.hotreload

Examples of honeycrm.server.test.small.dyn.hotreload.DatastoreClassLoaderDelegate


  public void testDynamicLoadingFromJarFileWithOneClass() {
    try {
      ResourceStore r = new ResourceStore(db, "Classes");
      r.put(store.getBytecodeMapFromJarInputStream(new FileInputStream(FILE)));
     
      InterceptClassLoader loader = new InterceptClassLoader(getClass().getClassLoader(), Pattern.compile(PATTERN), Arrays.asList(new DatastoreClassLoaderDelegate(r)));
     
      Class c = loader.loadClass("honeycrm.server.test.small.DynamicallyLoadedClass", true);
      //assertTrue(c.newInstance() instanceof Plugin);
      // Plugin p = (Plugin) c.newInstance();
      // assertEquals("42", p.request());
View Full Code Here


  }
 
  public void testDynamicLoadingFromJarFileWithTwoClasses() {
    try {
      ResourceStore r = new ResourceStore(db, "Classes");
      InterceptClassLoader loader = new InterceptClassLoader(getClass().getClassLoader(), Pattern.compile(PATTERN), Arrays.asList(new DatastoreClassLoaderDelegate(r)));
     
      r.put(store.getBytecodeMapFromJarInputStream(new FileInputStream(FILE2)));
     
      Class c = loader.loadClass("honeycrm.server.test.small.DynamicallyLoadedClass");
      // assertTrue(c.getInterfaces()[0].equals(Plugin.class));
View Full Code Here

TOP

Related Classes of honeycrm.server.test.small.dyn.hotreload.DatastoreClassLoaderDelegate

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.