Arunkumar Khannur's Software Testing Knowledge Center
2.3 Unit Testing
Unit is made up of code that is composed of process and data. Process consists of arithmetic and logical operations. Data at unit level is about selection and usage of data structures within the code. Unit testing focuses on data and process, and evaluates for syntax, semantics, compliance with coding standards, and programming style. Thus unit testing uncovers as many arithmetic and internal logic errors as possible, check for correct selection and usage of data entry fields and data structures, compliance with coding standards and programming style. A thorough unit testing will detect many errors at the initial phase of the software development where they can be corrected economically. In Unit Testing the emphasis is on removing coding errors (typos, basic logic problems, syntax errors). In some cases, code inspection and walkthroughs are used to verify the basic functionality and normal processing paths prior to beginning unit test. Some contracts, where some of the software is COTS, do not permit state visibility into unit testing.

The purpose ofunit testing is to verify individual hardware or software units, or small groups of related code unit. In Unit Testing, the emphasis is on removal of basic coding errors and also, compliance with programming style and standards.
  • Unit Test Expectations
  • Unit Test Considerations
  • Tasks in Unit Testing
Khannur's Book
Arunkumar Khannur, Software Testing - Techniques and Applications, Published by Pearson Publications, 2011 (ISBN:978-81-317-5836-6; Pages:341 + xxii)
Follow Khannur
Khannur's Company
ISQT Process & Consulting Services Pvt. Ltd., Bangalore, INDIA
Khannur's Software Testing Forum
 Contact Khannur
ISQT Process & Consulting Services Pvt. Ltd.
#732, 1st Floor, 12th Main,
3rd Block, Rajajinagar,
Bangalore - 560010, INDIA
Phone: +91 80 23012511
Skype: arun.isqt