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?

If Clover is instrumenting SOURCE, then yes, that would work, but I
have never heard of that approach (and haven't used Clover in 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 getting Clover to 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 that Clover works, it does not copy over the *.gwt.xml
> files unless you do a little something extra.  Thus, During the part
> of the Clover lifecycle 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 since Clover instruments 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, Clover is 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 with Clover.  (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 of Clover, 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
> > > Clover classes.
>
> > > 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to