Is there a way to unpack a tuple containing boolean and custom message and apply assert on it in single line single statement?
def test_numbers(a,b):
if a==b:
return True,"Are Equal"
return False, "Not equal"
res, st = test_numbers(1,2)
assert res,st
Then tried the following, which didn’t work
assert *test_numbers(1,2)
same for:
assert (*test_numbers(1,2))