I am suppose to assert my code function to make sure they are running smoothly but I am not sure how I should go about this. The function itself makes a widget disappears and the reappears if the user clicks on it again.
For example,
yes = w.ToggleButton(description="I'll be there!")
def yes_ans(y):
    with out:
        if y['new']:  
            display(name, 
                    food, 
                    friends_1, 
                    friends_2, 
                    send)
        else:
            out.clear_output()
yes.observe(yes_ans, 'value') 
How should I assert this? I don't know if what I am saying is clear, but any help would be great thank you.
assert i_expect_this_to_be_true == True and i_expect_this_to_be_false == False