Sunday, August 26, 2007

Fault Insertion Testing

I don't understand why test engineers only want to test the Go path, the path that gives you that nice green "PASS" screen, if you're using NI TestStand. I will admit the "green screen of goodness" does give you that good feeling. However, testing doesn't always get the Pass screen, sometimes Units Under Test (UUT) fail. Test engineers need to make sure these failures can be caught. That means when running their code, test engineers need to insert faults.

I've heard to many engineers they don't have time for fault insertion, "it takes to long", "I don't know how", "I can't". Blah, Blah, Blah. Think about the cost and embarrassment when a UUT gets through. Sometimes faults aren't thought of because they're in the future so they'll be verified later. Typically they're forgotten about after that.

The only faults that should not be inserted and verified to be caught are if the fault insertion could damage the UUT or the Test Equipment. Any other faults should be open for testing.

There are ways to insert almost every fault when you're testing a UUT. Some easy, some hard. Any fault that has a high probability of happening or a fault that can cause major problems needs to be verified that it can be caught. Sometimes it can be as simple as pulling a plug from a break out box, sometimes you have to get more creative.

Once, in order verify I could catch communications fault over a channel I had no control over, I temporarily added a function to the communications driver that allowed me to add errors to in coming messages. While this was not allowable in the final test configuration (no extraneous code in the final version) it did allow me to insert error's in order to verify my code.

Not enough people have the imagination to come up with ways to verify their test code works. They write and just assume it will work. This is a huge mistake made by many test engineers and not caught until the they're in front of the customer.

I was thinking about this because I was going to use a test set (the test engineer wasn't in the room) and disconnected the cable between the test set and the UUT. It was then I noticed a test was running and about half the tests were still passing. They shouldn't have been passing. Apparently there wasn't enough fault insertion done.

1 comment:

Anonymous said...

Reading your comments about forgetting to add some fault cases made me think that you could use NI Requirements Gateway. It "matches" requirements from different documents (e.g: Word, PDF, etc) with NI Tools (TestStand sequence, LabVIEW, CVI, etc). That was, you can quickly see if you have implement everything or how much is left and where it was implemented.

Check this tutorial that gives you more info:
http://zone.ni.com/devzone/cda/tut/p/id/3721

Hope this helps,

Vincent Carpentier
NI Quebec Field Sales