Had to do it unfortunately because the one in testvars did not work for me. And having an extra key to hold the port in the testvars probably will not make much sense. But, I guess this can be done in setUp, or rather the MockEmail class' __init__ method. Would this be the right way to do it?