FacetNotFoundException after setup in tests
by Rafael Pestano
Hi guys.
I'm facing a problem when testing an addon setup command, here is some code:
@Test
public void testSwaggerSetup() throws Exception {
//facetFactory.install(project, SwaggerFacet.class);
try (CommandController controller =
uiTestHarness.createCommandController(SwaggerSetupCommand.class,
project.getRoot())) {
controller.initialize();
Assert.assertTrue(controller.isValid());
final AtomicBoolean flag = new AtomicBoolean();
controller.getContext().addCommandExecutionListener(new
AbstractCommandExecutionListener() {
@Override
public void postCommandExecuted(UICommand command,
UIExecutionContext context, Result result) {
if (result.getMessage().equals("Swagger setup
completed successfully!")) {
flag.set(true);
}
}
});
controller.execute();
Assert.assertTrue(flag.get());
SwaggerFacet facet = project.getFacet(SwaggerFacet.class);
Assert.assertTrue(facet.isInstalled());
I receive 'No Facet of type [interface
com.tdc.addon.swagger.facet.SwaggerFacet] is installed.
org.jboss.forge.addon.facets.FacetNotFoundException'" when i try to get
facet:
project.getFacet(SwaggerFacet.class);
if I uncomment "facetFactory.install(project, SwaggerFacet.class);" the
test passes.
I've debuged setup command and the facet is installed (temp project pom is
updated after setup) and 'flag.get()' returns true.
Any hints?
souces are here:
https://github.com/rmpestano/swagger-addon/blob/master/src/test/java/com/...
<https://github.com/rmpestano/swagger-addon/blob/master/src/test/java/com/...>
thanks in advance.
--
<http://www.advancedit.com.br/>Att,
Rafael M. Pestano
Desenvolvedor Java Cia. de Processamento de Dados do Rio Grande do Sul
http://rpestano.wordpress.com/
@realpestano <https://twitter.com/realpestano>
9 years, 2 months
Forge meeting minutes - 2015-09-15
by George Gastaldi
==============
#forge Meeting
==============
Meeting started by gastaldi at 14:05:27 UTC. The full logs are available
athttp://transcripts.jboss.org/meeting/irc.freenode.org/forge/2015/forge....
.
Meeting summary
---------------
* Agenda (gastaldi, 14:05:43)
* Priorities (gastaldi, 14:06:43)
* There is an issue that is blocking JBoss Tools 4.3.0.CR1 for being
released: JBIDE-20678 I am working on it , still haven't been able
to reproduce it (gastaldi, 14:08:00)
* Forge 2.19.1.Final will be released today (or still this week)
(gastaldi, 14:08:29)
* There is a JIRA that lists some "priority" tasks for the coming talk
of agoncal and antoine_sd FORGE-2470 (agoncal, 14:09:19)
* Roaster 2.16.0.Final was released yesterday, and that includes
support for implementing interfaces (gastaldi, 14:09:22)
Meeting ended at 14:27:26 UTC.
Action Items
------------
Action Items, by person
-----------------------
* **UNASSIGNED**
* (none)
People Present (lines said)
---------------------------
* gastaldi (14)
* jbott (4)
* agoncal (3)
* jbossbot (3)
* vineetreynolds (0)
Generated by `MeetBot`_ 0.1.4
.. _`MeetBot`: http://wiki.debian.org/MeetBot
9 years, 2 months
Suggestions for reusing InputComponent's setup
by George Gastaldi
Hello,
Antonio Goncalves pointed out in https://issues.jboss.org/browse/FORGE-2331
(also in https://issues.jboss.org/browse/FORGE-2469) that some input
configurations could be reused.
For example, the targetPackage although is used in several commands, is
initialized differently on some commands.
What would you think it would be a nice strategy to reuse
UIInputComponents?
Based on Antonio's suggestions, I have elaborated 2 proposals:
1) Introduce specializations of UIInput:
Eg: @Inject private TargetPackage targetPackage; (Where TargetPackage
extends UIInput<String>)
More info here:https://gist.github.com/gastaldi/46b3f38bc38c5efcc0ba
2) Move the component creation to utility classes:
eg: @Inject InputFactory factory;
and in the initializeUI of the UICommand:
targetPackage = factory.createTargetPackage(builder) ;
Of course, we could have a mix of both, but I would like to know your
thoughts about each proposal.
Best Regards,
--
*George Gastaldi | Senior Software Engineer*
JBoss Forge Team
T: +55 11 3524-6169
M: +55 47 9711-1000
9 years, 2 months
Forge meeting minutes - 2015-09-08
by George Gastaldi
==============
#forge Meeting
==============
Meeting started by gastaldi at 14:01:09 UTC. The full logs are available
athttp://transcripts.jboss.org/meeting/irc.freenode.org/forge/2015/forge....
.
Meeting summary
---------------
* Agenda (gastaldi, 14:01:55)
* Status report and priorities (gastaldi, 14:05:22)
* gastaldi is now the project lead of the JBoss Forge project :-)
(gastaldi, 14:05:57)
* I have been working in making the CI server smooth. Builds are now
blue in https://forge.ci.cloudbees.com/job/forge-core/ (gastaldi,
14:07:44)
* I also have been profiling Forge to minimize startup time and detect
hotspots that would need attention (gastaldi, 14:08:35)
* I have converted most of the available core addons to use the simple
container, hence avoiding starting a lot of Weld instances
(gastaldi, 14:12:07)
* I will still investigate Performance this week and will work on the
specialized inputs demanding feature (gastaldi, 14:13:46)
* antoine_sd and I will be giving a University on CDI + Forge at
Devoxx BE and Devoxx MA in November (agoncal, 14:25:08)
* Specializing UIInputs (gastaldi, 14:28:42)
* agoncal and I have been discussing about a better way to reuse
UIInput settings (eg FORGE-2469 and FORGE-2331) (gastaldi,
14:30:17)
* basically we'll provide means to construct specializations of
InputComponents (UIInput, UIInputMany, UISelectOne, UISelectMany) on
top of the existing API (gastaldi, 14:31:57)
* regarding the implementation, inheritance is not the solution as the
InputComponents are built by the InputComponentFactory. The solution
lies in creating delegators (or also call them decorators)
(gastaldi, 14:33:04)
* gastaldi is now working on this and will send and e-mail to the
forge-dev list along with a pull-request for further discussion with
the proposed solution (gastaldi, 14:33:55)
Meeting ended at 14:37:24 UTC.
Action Items
------------
Action Items, by person
-----------------------
* **UNASSIGNED**
* (none)
People Present (lines said)
---------------------------
* gastaldi (26)
* jbott (6)
* agoncal (3)
* vineetreynolds (0)
Generated by `MeetBot`_ 0.1.4
.. _`MeetBot`: http://wiki.debian.org/MeetBot
9 years, 2 months
Forge Meeting minutes - 2015-09-01
by George Gastaldi
==============
#forge Meeting
==============
Meeting started by gastaldi at 14:06:42 UTC. The full logs are available
athttp://transcripts.jboss.org/meeting/irc.freenode.org/forge/2015/forge....
.
Meeting summary
---------------
* Agenda (gastaldi, 14:07:03)
* Current status/Priorities (gastaldi, 14:09:03)
* Forge 2.19.0.Final was released yesterday. I still need to write a
blog post announcement (gastaldi, 14:09:45)
* Performance is still priority #1 (gastaldi, 14:09:59)
* with Forge 2.19.0.Final we improved the performance by converting
some addons to use the simple container instead of Weld (gastaldi,
14:10:34)
* I believe that there is more room for performance improvement in the
Furnace runtime implementation. (gastaldi, 14:11:26)
* I have been testing https://forge.ci.cloudbees.com/ as the CI server
for Forge. Still presents some failures while building but it's
configured to build pull-requests too (gastaldi, 14:13:28)
* gastaldi is working hard on improving the performance by profiling
Forge and introducing improvements to our algorithms (gastaldi,
14:15:17)
* GSoC final evaluations (gastaldi, 14:20:58)
* the Docker addon passed the final evaluation and it's ready to be
used: https://www.youtube.com/watch?v=QIng-S6_xhI (gastaldi,
14:26:54)
* unfortunately the Database Migration addon failed the final
evaluation as it's not building and lacks several features
(gastaldi, 14:27:48)
Meeting ended at 14:36:42 UTC.
Action Items
------------
Action Items, by person
-----------------------
* **UNASSIGNED**
* (none)
People Present (lines said)
---------------------------
* gastaldi (31)
* jbott (6)
* lincolnthree (3)
* jbossbot (3)
* agoncal (2)
* koentsje (0)
Generated by `MeetBot`_ 0.1.4
.. _`MeetBot`: http://wiki.debian.org/MeetBot
9 years, 2 months