You can test exception handling by using the test tool to deliberately cause an error, for example sending an IDoc with an empty mandatory field.
Prerequisites
You must have completed the required steps in
Defining and Using a Basic Type. You must ensure that your source text calls exception handling (or triggers exception handling in ALE inbound processing using the workflow return parameters) and sets the status value 51.Procedure
In the example, you should delete the value from the segment field