[asterisk-commits] mnicholson: testsuite/asterisk/trunk r124 - /asterisk/trunk/asttest/lua/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Mar 24 14:39:02 CDT 2010


Author: mnicholson
Date: Wed Mar 24 14:38:59 2010
New Revision: 124

URL: http://svnview.digium.com/svn/testsuite?view=rev&rev=124
Log:
Added a skip_if function.  Not to be mistaken with Skip-It.

Modified:
    asterisk/trunk/asttest/lua/testlib.lua

Modified: asterisk/trunk/asttest/lua/testlib.lua
URL: http://svnview.digium.com/svn/testsuite/asterisk/trunk/asttest/lua/testlib.lua?view=diff&rev=124&r1=123&r2=124
==============================================================================
--- asterisk/trunk/asttest/lua/testlib.lua (original)
+++ asterisk/trunk/asttest/lua/testlib.lua Wed Mar 24 14:38:59 2010
@@ -68,6 +68,14 @@
 -- utility functions
 --
 
+-- skip if the given condition is met
+function skip_if(condition, message)
+	if condition then
+		return skip(message)
+	end
+end
+_G.skip_if = skip_if
+
 -- fail if the given condition is met
 function fail_if(condition, message)
 	if condition then




More information about the asterisk-commits mailing list