Loading ...
Sorry, an error occurred while loading the content.

Re: [XP] Re: redundant code

Expand Messages
  • Phlip
    ... At refactor time, suppose I can t get rid of statement X. Test X defends X. But nothing in the system automatically
    Message 1 of 37 , Nov 19, 2003
    • 0 Attachment
      Ken Boucher wrote:

      > Ok. This is apparently just my lack of understanding but as long as
      > everything is working what, exactly, is the problem? What is so
      > horrible about possible redundancy that it's cost effective to hunt
      > it down and kill it when it's not exhibiting any problems?

      At refactor time, suppose I can't get rid of statement X.

      Test X' defends X.

      But nothing in the system >automatically< tell me nothing defends Test X'.
      The test specifies behavior that the Onsite Customer does not want. He
      either did ask for it, or asked but then rescinded. Suppose UserStory X''
      specified it, but months later UserStory X` requested behavior that we don't
      realize cancels out some behavior from UserStory X''.

      So, when cleaning the code, I can't clean out X. It's technically cruft now,
      but nothing in the process will automatically tell me that.

      We do all this testing to automate the check that a change is safe. But
      those tests might be hyperactive - they might fault a change which would
      have made end-user more productive.

      This risk is low in the noise, but we can't automate it away.

      --
      Phlip
    • George Paci
      ... You might want to take a look at Jester: http://jester.sourceforge.net/ (as opposed to http://www.geocities.com/xtremetesting/anecdotes.html ) --George
      Message 37 of 37 , Dec 1, 2003
      • 0 Attachment
        WILLIAMS Dominic wrote:

        > Well, it seems to me it /can/ be automated, and I have started working
        >
        > on an experimental tool with precisely that aim. My thinking is that
        > by mutating code (including "deletion" as a mutation), and seeing what
        > that does to /acceptance tests/ (not just unit tests), you could
        > detect that something needs attention. The tool will /highlight/ code
        > that can be mutated without breaking acceptance tests, and let the
        > programmer either add acceptance tests or automatically delete the
        > code.
        >
        > Does that sound like it would answer the problem?

        You might want to take a look at Jester:

        http://jester.sourceforge.net/

        (as opposed to http://www.geocities.com/xtremetesting/anecdotes.html )

        --George

        There is nothing to be found in a beehive that is not submerged in a
        bee. And yet you can search a bee forever with cyclotron and
        fluoroscope, and you will never find a hive. --Kevin Kelly
      Your message has been successfully submitted and would be delivered to recipients shortly.