Source Instrumentation Overview

From STRIDE Wiki
Revision as of 00:22, 22 January 2010 by Marku (talk | contribs) (Created page with 'Source instrumentation is the process by which developers and domain experts selectively instrument the source under test for the purpose of writing test scenarios against the ex…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Source instrumentation is the process by which developers and domain experts selectively instrument the source under test for the purpose of writing test scenarios against the executing application. Here are the requirements for source instrumentation using the STRIDE Framework:

  • define the STRIDE_ENABLED preprocessor macro in your build system.
  • include the srtest.h header file. This file included in the STRIDE Runtime source distribution.
  • selectively instrument strategic locations in your source code with Test Point or Test Log macros.

The process of instrumenting the source under test requires domain expertise to maximize the benefit of instrumentation. Here are some general suggested source code areas to consider instrumenting to gain insight and testability:

  • critical function entry/exit points
  • high value and exceptional callbacks
  • state transitions
  • critical or interesting data transitions (using optional payload to convey data values)