def METHOD_NAME(
    self, properties, path, pg_properties, pg_path, cfn, scenario
):
    """test for each scenario"""
    results = []
    pg_conditions = cfn.get_conditions_from_path(cfn.template, pg_path)
    # test to make sure that any condition that may apply to the path for the Ref
    # is not applicable
    if pg_conditions and scenario:
        for c_name, c_value in scenario.items():
            if c_name in pg_conditions:
                if c_value not in pg_conditions.get(c_name):
                    return results
    if self.is_cluster_enabled(
        cfn.get_value_from_scenario(pg_properties, scenario)
    ):
        c_props = cfn.get_value_from_scenario(properties, scenario)
        automatic_failover = c_props.get("AutomaticFailoverEnabled")
        if bool_compare(automatic_failover, False):
            pathmessage = path[:] + ["AutomaticFailoverEnabled"]
            if scenario is None:
                message = '"AutomaticFailoverEnabled" must be misssing or True when setting up a cluster at {0}'
                results.append(
                    RuleMatch(
                        pathmessage, message.format("/".join(map(str, pathmessage)))
                    )
                )
            else:
                message = '"AutomaticFailoverEnabled" must be misssing or True when setting up a cluster when {0} at {1}'
                scenario_text = " and ".join(
                    [f'when condition "{k}" is {v}' for (k, v) in scenario.items()]
                )
                results.append(
                    RuleMatch(
                        pathmessage,
                        message.format(
                            scenario_text, "/".join(map(str, pathmessage))
                        ),
                    )
                )
        num_node_groups = c_props.get("NumNodeGroups")
        if not num_node_groups:
            # only test cache nodes if num node groups aren't specified
            num_cache_nodes = c_props.get("NumCacheClusters", 0)
            if num_cache_nodes <= 1:
                pathmessage = path[:] + ["NumCacheClusters"]
                if scenario is None:
                    message = '"NumCacheClusters" must be greater than one when creating a cluster at {0}'
                    results.append(
                        RuleMatch(
                            pathmessage,
                            message.format("/".join(map(str, pathmessage))),
                        )
                    )
                else:
                    message = '"NumCacheClusters" must be greater than one when creating a cluster when {0} at {1}'
                    scenario_text = " and ".join(
                        [
                            f'when condition "{k}" is {v}'
                            for (k, v) in scenario.items()
                        ]
                    )
                    results.append(
                        RuleMatch(
                            pathmessage,
                            message.format(
                                scenario_text, "/".join(map(str, pathmessage))
                            ),
                        )
                    )
    return results