Export (0) Print
Expand All
Expand Minimize

HandlerFunctions Property

Specifies the handler functions that are used by the test function.

C/AL test functions on test codeunits. A test function is a function that has the FunctionType Property set to Test.

The handler function name as specified on the Functions tab of the C/AL Global window for the test codeunit.

Ee414241.note(en-us,NAV.70).gifNote
If the test function uses more than one handler function, then you should separate the handler function names by a comma.

You use test codeunits and test functions to test your application. A handler function allows you to automate tests by handling instances when user interaction is required by the code that is being tested. In these instances, the test function calls the handler function, which is run instead of the user interface.

The following is some important information about handler functions:

  • To be a handler function, the FunctionType Property must set to one of the handler types: MessageHandler, ConfirmHandler, StrMenuHandler, PageHandler, ModalPageHandler, or ReportHandler.

  • A test function can only call handler functions that are defined in the same test codeunit as the test function.

  • A test function can call MessageHandler, ConfirmHandler, and StrMenuHandler type handlers only once. It can call PageHandler, ModalPageHandler, and ReportHandler type handlers multiple times but only once per application object ID.

  • Every handler function that you enter in the HandlerFunctions property must be called at least once in the test function. If you execute a test function that has a handler function listed that is not called, then the test fails.

For more information, see Testing the Application and How to: Create Handler Functions.

Show:
© 2015 Microsoft