def test_normal_phone_number(self): test_number = '(56-32) 1234567' self.assertEqual('+56321234567', process_phone_number(test_number))
def test_short_phone_number(self): test_number = '1234' self.assertIsNone(process_phone_number(test_number))
def test_dashed_spaced_number(self): test_number = '32-250 46 04' self.assertEqual('+56322504604', process_phone_number(test_number))
def test_dashed_parenthesis_number(self): test_number = '(56) 32 2504156' self.assertEqual('+56322504156', process_phone_number(test_number))
def test_spaced_number(self): test_number = '32 2504040' self.assertEqual('+56322504040', process_phone_number(test_number))
def test_dual_number(self): test_number = '322504225-322504658' self.assertEqual('+56322504225', process_phone_number(test_number))
def test_already_formatted_number(self): test_number = '+56321234567' self.assertEqual(test_number, process_phone_number(test_number))
def test_no_string_number(self): test_number = 1234 self.assertIsNone(process_phone_number(test_number))
def test_short_phone_number_with_code(self): test_number = '(56-32) 123456' self.assertIsNone(process_phone_number(test_number))