Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

assert in python

x = "aaa"

#if condition returns False, AssertionError is raised:
assert x == "aaa", "x should be 'aaa'"
Source by www.journaldev.com #
 
PREVIOUS NEXT
Tagged: #assert #python
ADD COMMENT
Topic
Name
6+2 =