mock object
Home > Software Quality Glossary > Definition - mock object
EMAIL THIS
Glossary - powered by WhatIs.com
 BROWSE ALPHABETICALLY:    A B C D E F G H I J K L M N O P Q R S T U V W X Y Z #    
Search for: in Full Target Search with Google

mock object

A mock object is a simulated object that mimics the behavior of a real object in controlled ways. Mock objects are often employed in unit testing to scrutinize the performance of actual objects. In this context, an object is the smallest testable part of an application. A mock object makes use of the same interface as the element of code it is intended to imitate.

A mock object can be useful in place of a real object that:

  • Runs slowly or inefficiently in practical situations
  • Occurs rarely and is difficult to produce artificially
  • Produces non-deterministic results
  • Does not yet exist in a practical sense
  • Is intended mainly or exclusively for conducting tests.


Read more about it:
>>  IBM discusses some practical aspects of unit testing with mock objects.
>>  DevX offers alternatives to the use of mock objects in Extreme Programming.
>>  JSMock is an open-source library for testing JavaScript code using mock objects.

Last updated on: Mar 07, 2007
WHITE PAPERS  
Ensure Compliance with Sarbanes-Oxley Regulations for SAP
Newmerix

Automating the Patch Migration & Testing for Oracle E-Business Suite
Newmerix

Dramatically Speeding Up Testing Cycles and Lowering Costs for SAP
Newmerix

Oracle E-Business Suite: Dramatically Speeding Up Testing Cycles and Lowering Costs
Newmerix

Broadening Life-Cycle Support for ERP and Composite Applications
Newmerix

>> More White Papers
  WHAT'S NEW
 1. Managing performance in the enterprise
 2. Software testing fundamentals
 3. Learning Guide: Debugging & unit testing
 4. .NET Application Security Learning Guide


About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




All Rights Reserved, Copyright 2006 - 2008, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts