<p dir="ltr">That looks weird, what OS are you using? </p>
<div class="gmail_quote">Em 16/02/2016 04:13, &quot;Ivan St. Ivanov&quot; &lt;<a href="mailto:ivan.st.ivanov@gmail.com">ivan.st.ivanov@gmail.com</a>&gt; escreveu:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Gotcha!<div><br></div><div>So after instead of:</div><div><pre style="color:rgb(0,0,0);font-family:Inconsolata;font-size:16.5pt"><span style="background-color:rgb(255,229,153)">chosenFacet</span>.<span style="background-color:rgb(207,226,243)">install</span>();</pre></div><div>I did:</div><div><pre style="color:rgb(0,0,0);font-family:Inconsolata;font-size:16.5pt"><span style="background-color:rgb(207,226,243)">facetFactory.install</span>(getSelectedProject(uiExecutionContext), <span style="background-color:rgb(255,229,153)">chosenFacet</span>);</pre></div><div>Everything worked like a charm!</div><div><br></div><div>Thanks, George, for the quick reaction! :)</div><div><br></div><div>On a side note, what is wrong with the addon configuration, so that if I need to test any change I do in the impl module, I have to <font face="monospace, monospace">mvn clean <b>install</b></font> and only then run the test from tests module?</div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 16, 2016 at 12:37 AM, George Gastaldi <span dir="ltr">&lt;<a href="mailto:ggastald@redhat.com" target="_blank">ggastald@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><p dir="ltr">Hi Ivan,</p>
<p dir="ltr">The faceted object assigned in the facet instance will only be set when you install a facet (using the FacetFactory). </p>
<p dir="ltr">The facet values in the UISelectOne can only be used after they are installed in a given project.</p>
<p dir="ltr">Therefore, as a rule of thumb, don&#39;t expect the faceted object to be set on the Facet objects returned from UISelectOne.getValueChoices unless they are explicitly installed in the faceted project (eg FacetFactory.install() is called).</p>
<p dir="ltr">Best Regards,</p>
<p dir="ltr">George Gastaldi</p>
<div class="gmail_quote"><div><div>Em 15/02/2016 20:02, &quot;Ivan St. Ivanov&quot; &lt;<a href="mailto:ivan.st.ivanov@gmail.com" target="_blank">ivan.st.ivanov@gmail.com</a>&gt; escreveu:<br type="attribution"></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr">Hey everybody,<div><br></div><div>I am trying to add a test for the TestingSetupCommand, part of the testing addon, that I want to develop. What is particular about this command and the addon:</div><div><br></div><div>- They use the simple furnace container instead of cdi</div><div>- The command has UISelectOne input which values are supposed to be implementations of the TestingFacet interface (JUnitTestingFacet and TestNGTestingFacet)</div><div><br></div><div>The testing facet base class that is extended by both facet implementations has a method that returns the dependency facet of the currently selected project:</div><div><pre style="color:rgb(0,0,0);font-family:Inconsolata"><font size="4"><span style="color:rgb(0,0,128);font-weight:bold">private </span>DependencyFacet getDependencyFacet()<br>{<br>   <span style="color:rgb(0,0,128);font-weight:bold">return </span>getFaceted().getFacet(DependencyFacet.<span style="color:rgb(0,0,128);font-weight:bold">class</span>);<br>}<br></font></pre></div><div>And this method works fine when it is called when the test sets up the test project. However, when I &quot;select&quot; a testing framework form the UISelectOne, the value that I get back (in my case TestNGTestingFacet) does not have a valid origin field (it&#39;s null). Is it possible that upon setup the UISelectOne&#39;s items are not initialized properly?</div><div><br></div><div>You can check the code in my repository:</div><div><br></div><div><a href="https://github.com/ivannov/core/tree/FORGE-2545" target="_blank">https://github.com/ivannov/core/tree/FORGE-2545</a><br></div><div><br></div><div>Just put a breakpoint in AbstractTestingFacet::getDependencyFacet and run TestSetupCommandTest::testSetupTestNG. Check the content of the getFaceted() return value.</div><div><br></div><div>Thanks,</div><div>Ivan</div><div><br></div><div> </div></div>
<br></div></div>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div>
<br>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org" target="_blank">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div><br></div>
<br>_______________________________________________<br>
forge-dev mailing list<br>
<a href="mailto:forge-dev@lists.jboss.org">forge-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-dev</a><br></blockquote></div>