]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
tests: fix the main() documentation of ceph-helpers.sh 4782/head
authorLoic Dachary <ldachary@redhat.com>
Wed, 27 May 2015 14:16:34 +0000 (16:16 +0200)
committerLoic Dachary <ldachary@redhat.com>
Wed, 27 May 2015 14:54:25 +0000 (16:54 +0200)
It was incorrectly documented as calling the setup function. It was
also vague on how the environment was reset.

Signed-off-by: Loic Dachary <ldachary@redhat.com>
src/test/ceph-helpers.sh

index 3657c226d0baa7a698e339a1b29b09f2df860505..64667a4424da5a59ee7e2983690b940261a07532 100755 (executable)
@@ -1100,14 +1100,19 @@ function test_expect_failure() {
 
 ##
 # Call the **run** function (which must be defined by the caller) with
-# the **dir** argument followed by the caller argument list. The
-# **setup** function is called before the **run** function and the
-# **teardown** function is called after to cleanup leftovers. The
-# environment is prepared to protect the **run** function from
-# pre-existing variables.
-#
-# The shell is required to display the function a line number whenever
-# a statement is executed to facilitate debugging.
+# the **dir** argument followed by the caller argument list.
+#
+# **teardown** function is called when the **run** function returns
+# (on success or on error), to cleanup leftovers. The CEPH_CONF is set
+# to /dev/null and CEPH_ARGS is unset so that the tests are protected from
+# external interferences.
+#
+# It is the responsibility of the **run** function to call the
+# **setup** function to prepare the test environment (create a temporary
+# directory etc.).
+#
+# The shell is required (via PS4) to display the function and line
+# number whenever a statement is executed to help debugging.
 #
 # @param dir directory in which all data is stored
 # @param ... arguments passed transparently to **run**