Closed GoogleCodeExporter closed 9 years ago
Original comment by philippe.beaudoin
on 7 Apr 2010 at 5:17
Original comment by philippe.beaudoin
on 9 Apr 2010 at 6:08
Philippe, are you working on this issue?
I'm thinking about splitting ProxyGenerator to several classes. Something like
one per feature (place, tabs, gatekeeper). The generator instantiate one
instance of each and relies on them to generator code. They will act as method
writer into the resulting class or maybe block writer into one method. I need
to fully read 1000+ lines of code ;)...
Original comment by olivier....@free.fr
on 20 Jul 2010 at 8:28
I'd love this! I haven't been around to cleaning this... It kind of grew out of
hand and I couldn't see a nice clean way of organizing the code back in the
days... But please do it.
I wonder, though, before we attempt such a major refactoring, should we try to
build unit tests for the various code generation paths? Is this difficult to
do? (We probably need GwtTestCase...)
Original comment by philippe.beaudoin
on 20 Jul 2010 at 8:39
I've never find a good way to unit test my generators. It's missing something
with GWT to do it (some mock).
My plan is first to split ProxyGenerator into small methods using eclipse
"extract method" function. This will not change anything about generated code.
But it will change many for me ;).
Of course having unit tests for all code generator paths is the best way. But I
not sure to be able to do all.
This issue may be a big work but I think we need to do it before adding new
code.
Original comment by olivier....@free.fr
on 20 Jul 2010 at 9:02
I agree, it grew out of hands. And if we want to tackle Issue 69 it will help
if we already have a clean example implementation of generators.
I have tried to test a lot of the various generation code paths in the example
apps, and my production app here is another large test, so there may be enough
tests for us not to worry about unit testing prior to refactoring... I'll trust
your judgement on this one.
Original comment by philippe.beaudoin
on 20 Jul 2010 at 9:08
Original comment by philippe.beaudoin
on 22 Sep 2010 at 1:35
Original comment by philippe.beaudoin
on 22 Mar 2011 at 6:39
This was done a while back, pretty clean now, not sure why it wasn't closed...
Original comment by philippe.beaudoin
on 20 May 2011 at 4:23
Original issue reported on code.google.com by
philippe.beaudoin
on 27 Mar 2010 at 5:58