Re: Re: Ambiguous Refactoring Solution

Ron Jeffries <[email protected]>
Newsgroups gmane.comp.programming.refactoring
Message-ID <[email protected]>
Hello, John.  On Wednesday, September 23, 2009, at 12:20:13 AM,
you wrote:

> I'm a little bit worried about this direction. I mean, in the
> cycle red-green-refactor, we have no motive for the refactoring,
> other than some nebulous concept of code goodness. So, if you see
> a class that is too big, and you have some time to spend on
> improving your code base - then why not?

Some possible reasons why not follow. None of them may apply to the
present case, although I suspect that some do.

* If this class is working, and there are no stories to work on, our
  project may be done.

* Other than just for practice, refactoring a class that has no work
  impacting it is waste. For practice, it would be wise to work where
  there are tests.

* Inability to see anything worth improving and improve it in a 613
  line class suggests that we should start refactoring on something
  simpler.

* If we find ourselves unable to start on this class without a grand
  plan, perhaps we should focus on practicing small refactoring steps.

* If we are in need of becoming expert in refactoring, it would be
  wise to start where there are tests.

* If a class needs refactoring, and has no tests, the first thing to
  do is probably not to worry about large purposes for refactoring.
  The first thing to do may be to start getting it tested. This will,
  of course, drive some refactoring.

Ron Jeffries
www.XProgramming.com
www.xprogramming.com/blog
Only the hand that erases can write the true thing.  -- Meister Eckhart



------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/refactoring/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/refactoring/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[email protected] 
    mailto:[email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.