summaryrefslogtreecommitdiff
path: root/src/leap/common/check.py
diff options
context:
space:
mode:
authorTomás Touceda <chiiph@leap.se>2013-05-28 17:38:30 -0300
committerTomás Touceda <chiiph@leap.se>2013-05-28 17:38:30 -0300
commit205fcd6c6bb8712a115f3dfe738c490f5427e09b (patch)
tree0d824ab1fc1de09fe2136f1419a0a2966225fac4 /src/leap/common/check.py
parentb7dc270bce885ce5079d86d8e52fd96b8390fc9d (diff)
parent354467c605f07042568c10c3e931f7fc093c0bf4 (diff)
Merge remote-tracking branch 'kali/bug/allow-absolute-paths2' into develop
Diffstat (limited to 'src/leap/common/check.py')
-rw-r--r--src/leap/common/check.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/leap/common/check.py b/src/leap/common/check.py
index 359673b..a2d39a6 100644
--- a/src/leap/common/check.py
+++ b/src/leap/common/check.py
@@ -31,10 +31,10 @@ def leap_assert(condition, message=""):
Asserts the condition and displays the message if that's not
met. It also logs the error and its backtrace.
- @param condition: condition to check
- @type condition: bool
- @param message: message to display if the condition isn't met
- @type message: str
+ :param condition: condition to check
+ :type condition: bool
+ :param message: message to display if the condition isn't met
+ :type message: str
"""
if not condition:
logger.error("Bug: %s" % (message,))
@@ -51,10 +51,10 @@ def leap_assert_type(var, expectedType):
"""
Helper assert check for a variable's expected type
- @param var: variable to check
- @type var: any
- @param expectedType: type to check agains
- @type expectedType: type
+ :param var: variable to check
+ :type var: any
+ :param expectedType: type to check agains
+ :type expectedType: type
"""
leap_assert(isinstance(var, expectedType),
"Expected type %r instead of %r" %