Is Automated Software Testing Enough?

Automated testing is all the rave lately, but there is so much more around automated testing that we shouldn’t forget.  I was recently listening to a Scott Hanselmen talk with Queztal Bradley about testing.  Queztal is a software development engineer on Chris Sell’s team with a crazy amount of Real World Software Development experience, focusing around software testing.  They had a lot of fantastic points during their discussion, but if you don’t have time to listen to it, let me summarize some of the highlights.

Code Coverage is an Inverse Number

Let’s say you have 50% code coverage within your application.  In reality you have very little code coverage.  Why?  Well, you have about half of your application completely untested.  That is a scary scenario.  A nice analogy (I love analogies) is to look at it as if you live on 8 Mile in Detroit.  You have just installed locks on half of your doors in your house.  Does this really help you at all? 

I mean sure you should feel pretty good about yourself for installing the locks on half the entry points, but locks on only half of your doors and windows is not going to help you very much.  The burglar will just try everything anyway and get into your palace of software creation.  Even if you have locks on everything, can they still get in?  Absolutely! Just break a window.  And that’s where we get into the rest of the problems with just having 100% code coverage.

Sample Testing with Diverse Data

Dr. Watson One of the great concepts he talks about is getting your application to “phone home” to get data to put it into your unit tests.  I’ve always thought unit tests were great, but the problem is, how many variations of data are you running through your application.  How many times have I seen a software developer write a “wicked” unit test, that only really test a few variations of data.  Two problems here.  Not enough data to run the test with, and the second problem, is the data actually real world?  There are a bunch of ways you can get real world data from your users of course.

One great way to do this is to tie up a web service to your application to send data whenever exceptions occur within the application.  Do you remember Dr. Watson?  And no I’m not talking about Sherlock Holmes friend and confidante.  I’m talking about good old drwatson.exe!That application was probably one of the most used and important applications Microsoft ever created, and still uses today.

The other method of course is to phone up your customers and get real world data from them.  Most times they are more than happy to provide it to you.  You really need this data!  It’s simply not enough to write a unit test that tests a section of the application for one or two expected outputs, and only uses a few variations of the inputs.  This simply does not simulate a real world test, and really gives you a false sense of security.

State Coverage is Important

State coverage?  How many different “states” will your customer place your application in.  Are you testing for state coverage? State coverage measures whether unit-level tests check the outputs and side effects of the program.  State coverage is a whole other article which I will cover in the coming weeks, but you should definitely start looking into.  For example, state coverage will tell you exactly how many assert-less unit tests your software development buddies have written just to make sure they have code coverage.

Feedback and AdHoc Manual Testing

Software Development At the end of the day, all the automated testing in the world is not going to catch all of the issues with your application.  Let’s say you test your application, all seems well, but for some reason a button has turned purple.  Your automated tests won’t catch this.  Should you go and write a test to test this?  Write a test to test this for all buttons? Drop Downs?  This is a simple example of something that can be caught very easily by humans, but not so easily by computers.  While you can take your automated testing to a crazy level, sometimes you should stop and think if its really necessary.  There is always a place for Manual Testing.

When you receive feedback that a bug is in the software, or a manual test has been run by a software tester and a problem found, what do you do?  Probably 90% of you just go in and fix the problem.  Is this a good approach?  Not really.  What the feedback or manual testing has done is uncovered an issue with your current automated tests.  This is the absolute best time for you to go into the application, and write some unit tests.  Regression found? Excellent, write a unit test to re-create the regression, then fix the regression.  Run your tests. Is the regression fixed?

Anyway, you can listen to the show in its entirety at Hanselminutes.com

  • http://www.linkedin.com/pub/9/593/816 Inder P Singh

    You have made a good point about feedback and manual testing. Manual testing does provide value even when automated testing is extensively being used on the application. Not only can humans spot UI issues (like the purple button mentioned in the post) quickly, there are a number of situations where manual testing could prove more efficient:
    1. Checking if the requirements have been properly understood and have been completely and correctly implemented in the application
    2. Testing complex scenarios
    3. The application is changing so fast that the automated tests lag far behind
    4. Checking the usability characteristics of the application

    Inder P Singh

  • http://www.stylomart.com Shopping

    Great way to ensure software perfection.

  • http://www.myfacilitiesmanagementjobs.co.uk fm jobs

    thanks guys

  • http://www.christianlouboutindior.com christian louboutin

    good post,i like it

  • http://www.purelife-bags.com Coach bags

    Let’s say you have 50% code coverage within your application. In reality you have very little code coverage. Why? Well, you have about half of your application completely untested.

  • http://www.plastic-foam-machinery.com/ EPE foam extruder

    Polyethylene is buoyant, making it popular for nautical uses. PE foam sheet extruder Most types of polyethylene are non-abrasive; serve as a thermal insulator, are inert to water, grease and solvents at typical temperatures; are CFC-free and ozone friendly, recyclable, odorless, and very lightweight. PS foam sheet extruder Many types of polyethylene are approved for use in the food industry.
    Tongyi Company is a main foam machine manufacturer in today’s world. The main products of our company are PE foam sheet extrusion line, PE foam sheet extruder, Polyethylene foam extruder. PE foam sheet extrusion line As one main type of packaging, polyethylene is used to wrap frozen foods, sporting goods, furniture, computer components, clothing, electronics, metal products, plants, etc.PS foam sheet extrusion line

  • http://www.plastic-foam-machinery.com/ EPE foam extruder

    Polyethylene is buoyant, making it popular for nautical uses. PE foam sheet extruder Most types of polyethylene are non-abrasive; serve as a thermal insulator, are inert to water, grease and solvents at typical temperatures; are CFC-free and ozone friendly, recyclable, odorless, and very lightweight. PS foam sheet extruder Many types of polyethylene are approved for use in the food industry.
    Tongyi Company is a main foam machine manufacturer in today’s world. The main products of our company are PE foam sheet extrusion line, PE foam sheet extruder, Polyethylene foam extruder. PE foam sheet extrusion line As one main type of packaging, polyethylene is used to wrap frozen foods, sporting goods, furniture, computer components, clothing, electronics, metal products, plants, etc.PS foam sheet extrusion line

  • http://www.full-lace-front-wigs.com/wavy-full-lace-wigs-1-20inch-w401-p-308.html long lace front wigs

    potentially use the system. He and Wallace were concemed that All the managers now on the system had been well known to Batchelder, Culpepper, and Jones. As more people used the EIS, Batchelder knew these characteristics would change.

  • http://www.full-lace-front-wigs.com/beyonce-full-lace-wigs-4-18inch-cl01-p-310.html cheap wigs for sale

    25 people, had grown t0 50 by 1988 cheap wigs for sale and was responsible for more than 25 commercial systems development projects that involved computer support for managers, the management of

  • http://www.full-lace-front-wigs.com/wavy-full-lace-wigs-1-20inch-w401-p-308.html cheap long wigs

    These projects were in addition to the EIS project. Batch elder believed that his group served as an excellent training ground for a new breed of employee who understood both the business and

  • http://www.givenchyoutlet.com/ givenchy

    Thank givenchy you very much for your post, it is indeed wonderful to read your article,I like it very much.

  • zara
  • http://www.officialpatriotsshop.com/tom-brady-jersey Tom Brady Jersey
  • http://www.rlpolosales.com/shirts-m ralph lauren shirts

    Up-to-date Ralph lauren Polo Shirts Appears Modern Among Consumers

  • yabin

    Chanel outlet is dedicated to provide you the Chanel online, Chanel online store, Chanel Bags online all over the world with EMS, free shipping. To secure your order we adopt online credit card payment and for each items sold, 14 days money back guarantee is made.

  • http://www.borselouisvuitton-italy.com borse louis vuitton

    Gucci is one of the leading names in luxury and style. With its outstanding quality, fine Italian craftsmanship and exceptional beauty, Gucci outlet offers you only the best Gucci bags.We lead you to a genuine pool of bags the collections in wide range Gucci outlet online, discount Gucci, Gucci men bags, Gucci tote bags, Gucci on sale,and so on.gucci-bags-outlets.com are dedicated to bring you the top grade replicas gucci handbags. Cheap Gucci briefcase.We know that the quality of the product directly results in the impression given to people. Everyone hope to get noticed by their taste and elegant quality,Gucci Wallet, so our goal is to meet your demands. we believe that only focusing on quality can make us exist as long as possible. In addition to the good quality of Gucci bag,Gucci 85th Anniversary, we offer competitive pricing, our goal has been to earn the trust and satisfaction of the customer. We are determined to combine honest and helpful dealings with outstanding service before, during, and after the sale. Just go through on our for all Gucci collections,Gucci Backpack, and you could get all you want!

  • http://www.superlouisvuitton.com louis vuitton

    Welcome to http://www.lvbags-retail.com/! We are reliable provider dedicating to offering our customers high qualiy louis vuitton outlet online. Among our wide high quality and cheap louis vuitton uk product line that also includes cheap belts and designer wallets, Louis vuitton serious are the most competitive collection. You will never find another online shop that provides more fashion handbags of better quality at the same price range than us. Besides best quality and best price, we also guarantee louis vuitton luggage salefast delivery and excellent customer service.

  • http://www.cheapmonclersales.net/ cheapmonclersales

    Moncler Jackets is nothing more than put onCheap Moncler a jacket to a more Moncler Jackets UK comfortable and warm.

  • http://www.monclercheapeststore.com/moncler-cardere-pink-p-337.html moncler cardere

    Finding Moncler Outdoor jacketsmoncler cardere with a Deal Cost Moncler moncler cardereoutdoor jackets usually are last manner moncler cardereall over again, nevertheless, to tell the truth, moncler carderethey are often just a little high-priced. Where by are you able to come across inexpensive Monclermoncler cardere

  • http://www.moncler2you.com/ Moncler jas

    Moncler Netherland In 1957, om te voorkomen dat de vulstof Moncler jas product in korte aanbod en verhoging van Moncler Voor Heren de arbeidsparticipatie efficiency, Moncler is meer grondstoffen verplaatst naar Grenoble.Moncler Dames Jacks Moncler 1964 Terray door de sponsors opgezet vestigingen in Alaska. Moncler Down Vesten Vrouwen 1968, heeft Moncler geworden om deel te nemen in de GrenobleOlympische Winterspelen op de officiële de Tiende Franse nationale ski-team van

  • http://www.pandorabraceletaustralia.com pandora bracelets
  • http://www.teknocrat.com/wsdl-example-explained-step-by-step.html WSDL example