From e78be5c09eda6a8738d07d801dd8935f3eaa5400 Mon Sep 17 00:00:00 2001 From: Peter Andersson Date: Thu, 29 Sep 2011 00:21:27 +0200 Subject: Add documentation on timetraps and start flags --- lib/common_test/doc/src/write_test_chapter.xml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'lib/common_test/doc/src/write_test_chapter.xml') diff --git a/lib/common_test/doc/src/write_test_chapter.xml b/lib/common_test/doc/src/write_test_chapter.xml index 3f9fdb7121..e35888e68f 100644 --- a/lib/common_test/doc/src/write_test_chapter.xml +++ b/lib/common_test/doc/src/write_test_chapter.xml @@ -280,6 +280,8 @@ the timetrap time is exceeded, the test case fails with reason timetrap_timeout. Note that init_per_testcase and end_per_testcase are included in the timetrap time. + Please see the Timetrap + section for more details.

userdata @@ -699,8 +701,8 @@
- Timetrap timeouts + Timetrap timeouts

The default time limit for a test case is 30 minutes, unless a timetrap is specified either by the suite info function or a test case info function. The timetrap timeout value defined @@ -723,6 +725,13 @@ multipled by multiply_timetraps, and possibly scaled up if scale_timetraps is enabled, the function ct:sleep/1 may be called.

+

A function (fun or MFA) may be specified as timetrap value + in the suite- and test case info function, e.g:

+

{timetrap,{test_utils,get_timetrap_value,[?MODULE,system_start]}}

+

The function will be called initially by Common Test (before execution + of the suite or the test case) and must return a time value such as an + integer (millisec), or a {SecMinOrHourTag,Time} tuple. More + information can be found in the common_test reference manual.

@@ -818,6 +827,3 @@
- - - -- cgit v1.2.3