Hi Brian, Glad to hear you managed to get Clover working with the GWT maven plugin.
I would love to include that information in a FAQ entry in the Clover documentation. Did it basically just work out of the box for you, or were any extra steps required apart from ensuring there was a src/main/java and a src/main/resources directory? Also, a patch for allowing the gwt:compile to be skipped has already been committed to the maven-googlewebtoolkit2-plugin I believe: http://code.google.com/p/gwt-maven/issues/detail?id=197 Looking forward to having these two plugins merged into one! @Arthur - Please note that Atlassian offer free licenses of all their products (including Clover) to non-profits and open source projects. Application forms for these are online: http://www.atlassian.com/software/views/community-license-request.jsp http://www.atlassian.com/software/views/opensource-license-request.jsp Best Regards Nick Pellow Atlassian - Clover On Feb 21, 7:24 am, Arthur Kalmenson <arthur.k...@gmail.com> wrote: > Wow, that's really cool! I wish it wasn't so expensive (we're a non-profit). > > -- > Arthur Kalmenson > > On Fri, Feb 20, 2009 at 3:46 PM, Charlie Collins > > <charlie.coll...@gmail.com> wrote: > > > Ok, I decided to look a little closer atClover, and I am impressed, > > and my skepticism is rightly curtailed ;). > > > Looks like it does instrument source - and if that's the case > > basically all the problems go away. If the source is instrumented, you > > should be able to get it to work with any tools, just point the > > compiler at the instrumented source. > > > On Feb 20, 3:43 pm, Charlie Collins <charlie.coll...@gmail.com> wrote: > >> Well, if you got it working, I stand corrected then. Are you sure you > >> are getting coverage for your GWT client code, based on GWTTestCase > >> tests? > > >> IfCloveris instrumenting SOURCE, then yes, that would work, but I > >> have never heard of that approach (and haven't usedCloverin a few > >> years, every other code coverage tool I have use instrumented the > >> bytecode). So if it makes a COPY of the source, instruments there, and > >> then passes that to the compiler somehow, maybe, but that seems > >> extremely unlikely. The issues with instrumenting the GWT compiled > >> classes are that even if you compile them yourself and instrument > >> them, those aren't the ones GWT uses (the GWTCompiler does it's own > >> pass), and if you try to use an instrumenting classloader, that > >> doesn't have access either, in my experience (the compiler does it's > >> own classpath manipulation too). > > >> If you really have it working, then kudos, great job - but you will > >> forgive me if I am a bit skeptical (it might run fine, meaning not > >> blow up, but does it really report coverage info correctly?). > > >> Also, you don't need to worry about the patch, I am a committer on the > >> other plugin too, and am planning to merge this plugin in there at > >> some point. If you got it working with the Mojo plugin, just use that > >> one. > > >> On Feb 20, 6:45 am, "Brian H. Mayo" <brian.h.m...@gmail.com> wrote: > > >> > Actually, I was successful late yesterday gettingCloverto run end-to- > >> > end. > > >> > I looked up "the other" GWT maven plug > >> > in:http://mojo.codehaus.org/gwt-maven-plugin/ > > >> > This plugin has the ability for you to *not* specify the module and it > >> > will "scan" for them. You must have both a src/main/java and src/main/ > >> > resources directory. > >> > Given the way thatCloverworks, it does not copy over the *.gwt.xml > >> > files unless you do a little something extra. Thus, During the part > >> > of theCloverlifecycle after it has instrumented the .java files and > >> > called the compile part of the plugin, due to the fact that no > >> > *.gwt.xml files exists, the compile does nothing and the flow > >> > continues on. > > >> > The reporting is fine sinceCloverinstruments the java source code > >> > and "listens" in on the execution of the tests. Even though GWT has > >> > it own specific way of running the tests, with the source code > >> > instrumented,Cloveris able to capture the coverage data. > > >> > I would suggest adding this feature to this plugin as well. If I have > >> > time I will pull down the code, code it up, and submit it for > >> > consideration. > > >> > Regards, > >> > -Brian H. Mayo > > >> > On Feb 19, 6:50 pm, Charlie Collins <charlie.coll...@gmail.com> wrote: > > >> > > Your chances of getting coverage information are next to zero. Just > >> > > leave your GWT projects out of the code coverage mix, for now. The > >> > > GWT team is making this easier in GWT 1.6, but even then they use > >> > > Emma, and I am not sure if it will work withClover. (I would like to > >> > > see it work with any coverage tool, and they may be working on that > >> > > too, not sure.) > > >> > > The GWTCompiler isn't a regular compiler, of course, and GWTTestCases > >> > > are compiled and run by IT, not by regular javac. Even instrumenting > >> > > classloaders can't get to the JDT stuff the 1.5 and under compiler is > >> > > using. > > >> > > Here is a little more about the Emma > >> > > support:http://code.google.com/p/google-web-toolkit/wiki/EmmaSupport. > > >> > > I have used Emma with 1.5, with the patch, and my patch for the patch, > >> > > but it's a long > >> > > story:http://code.google.com/p/google-web-toolkit/issues/detail?id=779(note > >> > > that that says FixedNotReleased, maybe 1.6M1 would help, but it still > >> > > seems Emma focused to me) > > >> > > On Feb 19, 12:44 pm, "Brian H. Mayo" <brian.h.m...@gmail.com> wrote: > > >> > > > We are trying to setup our Continuous Integration environment and > >> > > > have > >> > > > hit a bit of a snag. > > >> > > > We are running Atlassian's Bamboo CI server. We have a parent > >> > > > project > >> > > > with child modules. We have a Web module with GWT. We use Maven2 > >> > > > for > >> > > > our build and dependency management. We are using Clover2 to handle > >> > > > our code coverage reporting. > > >> > > > In the lifecycle ofClover, at one point it instruments all code and > >> > > > calls compile. When it does this, the GWT Maven plugin attempts to > >> > > > compile the code into the Javascript. Since the code is fully > >> > > > instrumented, I get an error that it wants the source code for the > >> > > >Cloverclasses. > > >> > > > I am not sure what to do here, I image I can just simply put > >> > > > excludes > >> > > > in for all of the GWT client code that would participate in a Java to > >> > > > Javascript compile, but I do not want to do that (not even sure if > >> > > > that will work the way I am thinking). > > >> > > > Anybody out there with the same issue that has a work-around? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "gwt-maven" group. To post to this group, send email to gwt-maven@googlegroups.com To unsubscribe from this group, send email to gwt-maven+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/gwt-maven?hl=en -~----------~----~----~----~------~----~------~--~---