예제 #1
0
  private static void check(MimeType type, String str) throws Exception {
    References references;

    Node node = WORLD.getTemp().createTempFile();
    node.writeString(str);
    references = References.create(type, true, node);
    references.readBytes();
    node.deleteFile();

    System.gc();
    Thread.sleep(1000);

    System.out.println("Startup done");
    Thread.sleep(20000);
    System.out.println("computing ...");

    node = WORLD.getTemp().createTempFile();
    node.writeString(str);
    references = References.create(type, true, node);
    references.readBytes();
    node.deleteFile();

    System.out.println("busy wait to keep references");
    for (; ; ) ;
  }
예제 #2
0
 public static void main(String[] args) throws Exception {
   js(
       WORLD
           .file(
               "/home/mhm/Projects/order-modules/frontend-elements/src/main/resources/PUSTEFIX-INF/style/button.css")
           .readString());
 }
예제 #3
0
파일: LogDirectory.java 프로젝트: gelli/joe
 public LogDirectory(Class<?> testClass, World world) {
   this.testClass = testClass;
   try {
     baseDirectory =
         world
             .guessProjectHome(Class.forName(testClass.getName()))
             .join("target", SCREENSHOT_DIR)
             .mkdirsOpt();
   } catch (ClassNotFoundException | MkdirException e) {
     throw new RuntimeException("ToDo: Handle this", e);
   }
 }