Made the code for testing functions only run if it's called directly, not when imported as a module.