| By Aaron Godfrey | Article Rating: |
|
| July 15, 2011 09:15 AM EDT | Reads: |
417 |
Unit testing is a best practice in any modern methodology, including Agile development. With automatic unit testing in place, if we introduce a bug into the software, one or more tests will fail and we'll know about it immediately.
We've been writing in C++ for almost 30 years now, and we use software development tools, which improved over time. Yet, because of the intricacies of C++ and its different variants, testing tools did not become as advanced as Microsoft's Visual Studio .NET tools, or Eclipse for Java. For example, the testing tooling for C++ in Visual Studio lags behind the tools for the other languages supported in Visual Studio.
Without good software testing and development tools, it is hard to write quality code, and become more productive. More bugs enter the code, which makes us go slower and may introduce instability into the system. Where the tools are weak, we need unit tests even more.
But tooling is just one part of the problem. We have code bases sometimes almost 30 year old, that were not written with tests. They mostly work, but what happens when we discover a bug there? Fixing the bug without tests in place may be riskier than fixing it! In addition, nobody in their right mind would change 30 year old legacy code that works, just to make it fit for testing. That would be just as risky.
Because of these problems, unit testing adoption in C++ is slower than in other languages. Which is paradoxical: Many mission-critical systems (automobile, medical devices, etc.) are written in C or C++. There is regulation in place for systems like this, for that reason. Yet we don't do enough to ensure bugs don't get in.
But all is not lost. There are tools for unit testing in C++. They maybe not as easy to use, but this is a small price to pay, in order to make sure the products are top quality. This may even save lives.
Published July 15, 2011 Reads 417
Copyright © 2011 SYS-CON Media, Inc. — All Rights Reserved.
Syndicated stories and blog feeds, all rights reserved by the author.
More Stories By Aaron Godfrey
Aaron Godfrey writes on a variety of subjects including cloud, security, telecom, HTML5, software & software testing, bug-prevention and start-up markets. You are invited to follow @NCSM_PR
- Cloud Economics – Amazon, Microsoft, Google Compared
- The History of Programming
- Cloud Expo Silicon Valley Call for Papers Deadline July 29, 2011
- Edit Office Files on iPad, Android Tablets
- Developers Should Learn Why, Not Just Memorize What
- JNBridge Mates Java & .NET in the Cloud
- RESTful Web Services: A Quick-Start How-to Guide
- Microsoft Shows Off Win8 Tablet OS
- Cloud Expo Silicon Valley Show Prospectus Now Shipping
- High-Profile Investor Wants Ballmer Out
- Leveraging Cloud Storage for Massive Scale at Cloud Expo 2011 New York
- Office 365 on Tap
- Cloud Economics – Amazon, Microsoft, Google Compared
- The History of Programming
- Cloud Expo Silicon Valley Call for Papers Deadline July 29, 2011
- Edit Office Files on iPad, Android Tablets
- Developers Should Learn Why, Not Just Memorize What
- GISUser.com GIS Data, news, jobs, software tips, mashup news – Developing Location Based Services (LBS) Mobile Applications
- JNBridge Mates Java & .NET in the Cloud
- RESTful Web Services: A Quick-Start How-to Guide
- Microsoft Shows Off Win8 Tablet OS
- Cloud Expo Silicon Valley Show Prospectus Now Shipping
- Supremes Hear Microsoft-i4i Case
- High-Profile Investor Wants Ballmer Out
- Google Maps and ASP.NET
- Converting VB6 to VB.NET, Part I
- How to Write High-Performance C# Code
- Crystal Reports XI & How It Has Changed
- Creating Controls for.NET Compact Framework in Visual Studio 2005
- Where Are RIA Technologies Headed in 2008?
- Implementing Tab Navigation with ASP.NET 2.0
- Programmatically Posting Data to ASP .NET Web Applications
- AJAX World RIA Conference & Expo Kicks Off in New York City
- .NET Archives: Getting Reacquainted with the Father of C#
- i-Technology Photo Exclusive: Bill Gates & Steve Jobs In "Nerds"
- i-Technology Viewpoint: "SOA Sucks"
































