Re: Code Coverage and QC

From: Robert C. Martin (unclebob_at_objectmentor.com)
Date: 03/31/04


Date: Tue, 30 Mar 2004 23:41:03 -0600

On Tue, 30 Mar 2004 16:33:09 -0800, thoff <tmh@possibility.com> wrote:

>
>
>Jason Nocks wrote:
>> No, this is incorrect. Writing new code to replace old code is
>> rewriting, not refactoring! They are fundamentally different. This is a
>> common misconception.
>
>Jason, you are clearly on some kind of crusade on this.
>I understand what you are saying, but i do not agree
>on the strictness of your use. I don't think very
>many other people use refactoring to mean what you
>mean either.

While the term "refactoring" has fallen into common usage meaning
"change the code" the original intent, and the definition still used
in XP is:

 1. Refactoring. Noun. A very tiny modification to a program that
changes it's structure but does not change it's behavior as described
by existing unit tests.

2. Refactor. Verb. The act of making one or more refactorings to a
program for the purpose of improving it's structure.

-----
Robert C. Martin (Uncle Bob)
Object Mentor Inc.
unclebob @ objectmentor . com
800-338-6716

"Distinguishing between the author
and the writing is the essence of civilized debate."
           -- Daniel Parker



Relevant Pages

  • Re: How to do this?
    ... Kevin Spencer wrote: ... process of refactoring is an excellent way to solve a problem. ... A good developer will often begin by writing out a long solution, ... can be made into loops or functions, and other optimizations. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: How to do this?
    ... process of refactoring is an excellent way to solve a problem. ... A good developer will often begin by writing out a long solution, ... can be made into loops or functions, and other optimizations. ... Jon Skeet - ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: unit tests == ugly code?
    ... On of the TDD pitches is that the tests present a constant design pressure ... My test to check if my list articles works shows some strange semantics, ... If you are writing tests and not refactoring, I think you are missing a main ...
    (comp.lang.ruby)
  • Re: Language Features Id Like To See
    ... > The refactoring and other features in D2005 are a good ... but we need more automation to ... Refactoring, of course, doesn't help the writing but the rewriting. ...
    (borland.public.delphi.non-technical)
  • Re: Refactoring (Was: Code Coverage and QC)
    ... Jason Nocks wrote: ... > rewriting and refactoring? ... about code coverage, the example I used ... the program or read in from an external source.) ...
    (comp.object)