Updated the flashing function to work with 2+ animations. Added test statements and assertions at the end of the function to indicate a pass or fail