def test_parse_application_id_return_none(self): text_without_application_id = 'text without application id' result = parser.parse_application_id(text_without_application_id) self.assertIsNone(result)
def test_parse_application_id_aws_us_gov_partition(self): application_id = 'arn:aws-us-gov:serverlessrepo:us-gov-east-1:123456789012:applications/test-app' text_with_application_id = 'Application with id {} already exists.'.format( application_id) result = parser.parse_application_id(text_with_application_id) self.assertEqual(result, application_id)