def _get_expected_types(keyword_type, scope_type):
    """
    Get the actual type of the keyword based on the defined keyword types, and
    the scope type that is only useful when the defined type is 'inherited'.
    """

    if keyword_type == 'inherited':
        assert scope_type is not None, ("Scope type should not be None "
                                        "when checking inherited value")
        return [scope_type]

    if type(keyword_type) is list:
        return keyword_type
    else:
        return [keyword_type]