def METHOD_NAME(self):
    with self.assertRaises(errors.BaseVdkError) as context:
        errors.log_and_throw(
            to_be_fixed_by=errors.ResolvableBy.PLATFORM_ERROR,
            log=log,
            what_happened="(WHAT)",
            why_it_happened="(WHY)",
            consequences="(CON)",
            countermeasures="(MES)",
        )
    self.assertTrue(isinstance(context.exception, errors.PlatformServiceError))
    with self.assertRaises(errors.BaseVdkError) as context:
        errors.log_and_throw(
            to_be_fixed_by=errors.ResolvableBy.USER_ERROR,
            log=log,
            what_happened="(WHAT)",
            why_it_happened="(WHY)",
            consequences="(CON)",
            countermeasures="(MES)",
        )
    self.assertTrue(isinstance(context.exception, errors.UserCodeError))