def test_copy_email(self): """ Testing to see if our copying function is able to copy email address from a found contact. """ self.new_contact.save_contact() Contact.copy_email("007007007") """ pyperclip.paste returns whatever is copied on the machine's clipboard at that time. """ self.assertEqual(self.new_contact.email, pyperclip.paste())
def copy(number): """ Returns copied contact email address based on matching number. """ return Contact.copy_email(number)