EntityTranslator extends AbstractEntityAndManagerTranslator<Interface> { @Override protected Interface makeCodeGenModel(File file) { return newBuilder(file, getSupport().entityName()).build() .public_().add(getSupport().generatedEntityType()); } EntityTranslator(Injector injector, Table table);   }
@Test void makeCodeGenModel() throws InstantiationException { final Injector injector = Injector.builder() .withComponent(DelegateInfoComponent.class) .withBundle(TranslatorBundle.class) .withBundle(StandardTranslatorBundle.class) .build(); final Table table = DocumentDbUtil.traverseOver(Projects.SPEEDMENT_JSON.project(), Table.class).findFirst().orElseThrow(NoSuchElementException::new); final EntityTranslator translator = new EntityTranslator(injector,table); final File file = translator.get(); Generator generator = injector.get(Generator.class).orElseThrow(NoSuchElementException::new); final String code = generator.on(file).orElseThrow(NoSuchElementException::new); assertNotNull(code); }