When is a Defect a Defect?

For the past 9 months I've been working on a project that is dominated by a desire to have heavy documentation created prior to development work commencing.  As a result of this there is a trend to having things laid out in a place that the developer and tester can access.  Even with this style of development (also known as BDUF or waterfall) there are a lot of little things that don't get written in the documents and some larger things that get missed completely too.  Regardless of the tone I take in this post, those things need to be coded and provided to the client (assumption: the client really needs them).

What I've seen happen on my project in the last 9 months is a trend towards calling everything that is either broken or not included a defect.  The problem that I have is the determination that these are actually problems in the code.  Take for instance a scenario where the design document simply states that a screen should have a date picker on it and the ability for the user to select the date.  How is it that a tester can subsequently test that screen and then log a defect claiming that the date picker should not allow the user to select dates in the future?  I'm not arguing that this isn't what the client wants or needs, but rather how is this determined to be a defect?  I, as a programmer, can only code within the specifications and environment that I'm provided with.

If your process is to rely on heavy design documents, I will fall back to stating that "...the document didn't say it should do that", which is a very poor place to position myself.  The problem is that I can fall back on that with full confidence that I have a piece of verified and vetted paper that will back me up.  Another of my problems is that the testing is obviously being done based on a different set of expectations then what I am developing with.  Where does that second set of expectations come from?  Why does it exist?  Why are we fighting over the words on a piece of paper instead of working to get the client what they want?

For me, a defect occurs when we have created a piece of functionality that does not meet the needs of the client.  There are some gray areas (UI standards, consistency, etc.), but the majority of the time I find that answering "No" to the question "Is it what the client wants?" is the most effective way to make a determination.

I've never worked on a strong agile project before.  How do they handle the creation/definiton of defects when there can be so much client interation during the coding phase?  I assume that the increased client prescence dramatically decreases the opportunity for defects to arise, it's just how they are handled that I'm not overly clear on.  I'm going to be very glad to work on something non-waterfall in the future.  Let's just hope it's not two projects away.

posted @ Monday, September 24, 2007 2:13 PM

Print

Comments on this entry:

# re: When is a Defect a Defect?

Left by Tom Opgenorth at 9/24/2007 2:43 PM
Gravatar
I too have felt your pain in this matter. To me, it seems like the Sapir–Whorf hypothesis at work. People only know of "bugs" when software doesn't work the way they want it to - they don't have any other words for it. I suspect this is largely due to the tools we us. We have "bug trackers" and "defect management". These tools then get used to manage everything that is wrong with the software (actual or perceived).

# re: When is a Defect a Defect?

Left by Jason Meridth at 9/24/2007 3:15 PM
Gravatar
You are correct in assuming that defects decrease due to increased client presence throughout the coding process. However, there are still "enhancements" (aka changes) that come down the pipe do to client "realizations" during coding. With Extreme Programming (XP), one of the core principles is to "Embrace change". Convincing the client that it is an enhancement and not a defect is irrelavent. It is still something they want. You are completely correct in that regard.

As the Agile Manifesto states "Responding to change over following a plan".

Without sounding like a buzz-word dictionary, with practices like Test-Driven Development, Pair Programming, and increased client interaction defect count decreases dramatically.

It's the process that decreases the defects.

# re: When is a Defect a Defect?

Left by Joe Ocampo at 9/24/2007 3:38 PM
Gravatar
Your pain is felt be many just beginning Agile.

You have to remember that when you take on work the customers has desire and they have expectation. Both extremes are nebulous in nature and mutually exclusive. So what do you do to determine the middle ground?

Unfortunatly you are in a very difficult place since you have mentioned that the desire is BDUF. This has its drawbacks as I am sure you are encountering. But you can still take a stance from a "story" perspective. Take a requirement and turn it into a story.

"As a user the blank screen should have a date picker on it so that I can select a date."

This now serves as a discussion point for you and the customer to both collaborate around and ask one simple question, "What are you expecting the functionality to do in order for me to call this done?" Because you have established a dialog the customer may reply,

"just make sure the date picker is on the screen."

You say, "Are you sure there isn't anything else you need it to do? What about if they select a date in the future is that ok?"

Customer, "No, we don't want them to do that because....." etc.

So now you have your story defined and your acceptance test on how the functionality should behave. ANYTHING outside of the acceptance test is an enhancement that is simply embraced a new story. If your acceptance test fail than it is a defect.

The most important aspect of all this is dialog with the customer and understanding of what criteria constitute "done."


# re: When is a Defect a Defect?

Left by The Igloo Coder at 9/24/2007 4:52 PM
Gravatar
@Jason -- I agree with you completely on the Agile Manifesto. One of the things that I think is making it difficult for me to transition into that clear, and productive mindset with regards to "defects" is the environments that I've tried it in. When there is a "You got it wrong" stigma attached to every defect, it makes it hard to stay constructive over the long haul. Even harder is attempting to do this when you are blocked from any access to the client.

@Joe -- Thanks for the great little tutorial. It cleared up a couple of points for me that I tend to lose when I'm in the weeds. The first is that changes to acceptance tests should be treated as new stories. With that comes all the story things (estimating, prioritizing, etc.) that make the change manageable. The other was that the functionality of the date picker is flushed out by asking the right questions. If you can't/don't have a client to answer those questions you tend to do your best by shooting in the dark.

I'm not giving up on agile by any stretch. I had no intent for this post to end up as a discussion on agile methodologies, but I think it's fantastic that it did. Thanks to Los Techies for their input. Tequila on me when we meet boys.

# re: When is a Defect a Defect?

Left by Jason Meridth at 9/24/2007 4:59 PM
Gravatar
We'll hold you to the tequila offer. :)

Keep the good posts coming. This is the information that other non-Agile teams need to hear/think about.

# re: When is a Defect a Defect?

Left by Tom Opgenorth at 9/24/2007 5:34 PM
Gravatar
Tequila eh Don? Because it was so kind to you in Phoenix?

Your comment:



 (will not be displayed)


 
 
 
Please add 2 and 7 and type the answer here:
 

Live Comment Preview: