In a method that looks like:
def my_method(p):
if p == 5:
return
elif p == 6:
do_something()
return
else:
do_something_different()
return
How do I use Python unit test to check that when I call my_method(5) nothing extra is executed or changed outside my_method? I know that I can mock do_something and do_something_different and use assert_not_called but, is there a way to do it that only considers the if p == 5: part?