what is the meaning of assert false and assert true? | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
+ 4

what is the meaning of assert false and assert true?

28th Aug 2016, 10:16 AM
Anurag
Anurag - avatar
2 ответов
+ 7
it means it only return False or True..if false raise assertion error..if true No error ,and continue the execution.
28th Aug 2016, 11:59 AM
B. Chaithanya krishna
B. Chaithanya krishna - avatar
0
In assert True, you are asserting that the expression is true. If it is not, then it will display the message and the assertion will fail. In assert False, you are asserting that an expression evaluates to false. ... assert True (message, value == false) == assert False (message, value);
15th Jun 2020, 8:59 AM
Jesse Wasike
Jesse Wasike - avatar