Package juzu.impl.plugin.module.metamodel

Examples of juzu.impl.plugin.module.metamodel.ModuleMetaModel.toJSON()


          ).
          set("handle", "ElementHandle.Package[qn=metamodel.controller]").
          list("templates")
        )
      );
    assertEquals(expected, mm.toJSON());

    //
    List<MetaModelEvent> events = mm.getQueue().clear();
    assertEquals(2, events.size());
    assertEquals(MetaModelEvent.BEFORE_REMOVE, events.get(0).getType());
View Full Code Here


          ).
          set("handle", "ElementHandle.Package[qn=metamodel.controller]").
          list("templates")
        )
      );
    assertEquals(expected, mm.toJSON());

    //
    List<MetaModelEvent> events = mm.getQueue().clear();
    assertEquals(2, events.size());
    assertEquals(MetaModelEvent.BEFORE_REMOVE, events.get(0).getType());
View Full Code Here

    helper.assertCompile();

    //
    File ser = helper.getSourceOutput().getPath("juzu", "metamodel.ser");
    ModuleMetaModel mm = (ModuleMetaModel)Tools.unserialize(MetaModelState.class, ser).metaModel;
    assertEquals(expectedJSON, mm.toJSON());
  }

  @Test
  public void testParam() throws Exception {
    CompilerAssert<File, File> helper = incrementalCompiler("metamodel.param");
View Full Code Here

    helper.assertCompile();

    // Check
    File ser = helper.getSourceOutput().getPath("juzu", "metamodel.ser");
    ModuleMetaModel mm = (ModuleMetaModel)Tools.unserialize(MetaModelState.class, ser).metaModel;
    assertEquals(expectedJSON, mm.toJSON());
  }
}
View Full Code Here

            set("path", "foo.gtmpl").
            list("refs")
          )
        )
      );
    assertEquals(expected, mm.toJSON());
  }

  @Test
  public void testChangeValue() throws Exception {
    CompilerAssert<File, File> helper = incrementalCompiler("metamodel.path");
View Full Code Here

              set("path", "bar.gtmpl").
              list("refs")
          )
        )
      );
    assertEquals(expected, mm.toJSON());
  }

  @Test
  public void testRemoveAnnotation() throws Exception {
    CompilerAssert<File, File> helper = incrementalCompiler("metamodel.path");
View Full Code Here

          list("controllers").
          set("handle", "ElementHandle.Package[qn=metamodel.path]").
          list("templates")
        )
      );
    assertEquals(expected, mm.toJSON());
  }

  @Test
  public void testPathRemoveApplication() throws Exception {
    CompilerAssert<File, File> helper = incrementalCompiler("metamodel.path");
View Full Code Here

      set("applications",
        json().list("values")
      );

    //
    assertEquals(expected, mm.toJSON());
  }

  @Test
  public void testRefactorApplication() throws Exception {
    CompilerAssert<File, File> helper = incrementalCompiler("metamodel.path");
View Full Code Here

            set("path", "foo.gtmpl").
            list("refs")
          )
        )
      );
    assertEquals(expected, mm.toJSON());

    // Should also test objects....
    List<MetaModelEvent> events = mm.getQueue().clear();
    assertEquals(4, events.size());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.