SAP TEST-SEAM ABAP Statements



Get Example source ABAP code based on a different SAP table
  


ID TEST-SEAM
• TEST-SEAM ABAP Statement

TEST-SEAM
Short Reference

ABAP_SYNTAX
TEST-SEAM seam.
$[statement_block$]
END-TEST-SEAM.

What does it do?
The statement TEST-SEAM introduces a test seam called seam, which is closed by END-TEST-SEAM. A test class of the current program can use the statement TEST-INJECTION to replace the statement block statement_block with an injection defined there. If no injection is performed for the test seam, the original code is executed.
Test seams have the following properties:
Multiple test seams can be defined in a single compilation unit, but each must have a unique name.
The general naming conventions apply to the name seam.
Test seams cannot be nested, which means that a test seam cannot contain further test seams.
A test seam cannot extend beyond the limits of a statement block but can contain closed control structures.
A test seam can include data declarations. These declarations are not replaced when an injection is performed and remain visible in their context.
Test seams can be defined in the global declaration part of a program but not in the declaration part of a class.
A test seam can be empty, that is, it does not contain any statements. An injection is inserted instead.
Test seams cannot be defined in test classes.



Latest notes:

The injections for a test seam must be defined in the same compilation unit .
Injections can only be created in test