|
|
|
|
|
|
|
Re: Testing code generation [message #1817079 is a reply to message #1817078] |
Fri, 15 November 2019 08:13 |
|
no
your runtime module registers a generator that is empty now.
=> nothing is generated
=> either you need for standalone and test usecase a different module that has a generator that knows your external generators (explicitely or loading via service loader) and have a empty generator in ui module only.
=> or you teach your standalone usecase to call your external generators directly
Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
|
|
|
|
Re: Testing code generation [message #1817084 is a reply to message #1817081] |
Fri, 15 November 2019 09:52 |
|
i dont know what you have done in the first place.
=> create a new MyDslRuntimeModule2
=> let it extend from MyDslRuntimeModule
=> override bindIGenerator2 and return your custom generator class
=> create a Custom MyDslStandalone setup and customize
public Injector createInjector() {
return Guice.createInjector(new MyDslRuntimeModule());
}
to use your new module
create a custom injector provider
with
org.xtext.example.mydsl1.tests.MyDslInjectorProvider.createRuntimeModule()
overriden to use your module.
and use the new injector provider in your test
(or simply undo the generator in separate module thing)
Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
|
|
|
|
|
|
|
|
|
|
|
Re: Testing code generation [message #1817208 is a reply to message #1817205] |
Mon, 18 November 2019 14:50 |
|
i did a pr to your repo.
the injector and thus the module used by the injector provider needs to know your generator
(still the question: what is your deploymentconcept / reasoning behind moving to own generator)
looks like you dont address the standalone / test case there in general
Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: Testing code generation [message #1817786 is a reply to message #1817760] |
Fri, 29 November 2019 06:57 |
Nasri Mansa Messages: 36 Registered: October 2019 |
Member |
|
|
Thank you very much Christian, the problem is, MyDsl was created with eclipse version 2019-09( Dsl tools version) there are everything like xtext, emf and so on installed
but i want to install MyDsl plugin in eclipse version 2019-06 ( java version) , where i dont have any xtext, antlr ...
i can install my MyDsl plugin in eclipse version 2019-09(dsl tools) without any problem, but i can't install the same plugin in eclipse version 2019-06(java version)
to install this plugin ,
opened eclipse version 2019 -06 (java version)
choosed help-> install new software
in the "Work with" section clicked Add button , opened "Add repository" dialog and clicked Local
and selected directory of my updatesite, than appeared MyDsl
|
|
|
|
|
|
|
|
|
|
|
|