def METHOD_NAME():
    tgen = get_topogen()
    if tgen.routers_have_failure():
        pytest.skip(tgen.errors)
    step("Check if neighbor 192.168.255.254 is enabled for ipv4 address-family only")
    def _bgp_neighbor_ipv4_af_only():
        tgen.gears["r1"].vtysh_cmd(
            "conf t\nrouter bgp\nneighbor 192.168.255.254 remote-as external"
        )
        output = json.loads(tgen.gears["r1"].vtysh_cmd("show bgp summary json"))
        if len(output.keys()) == 1 and "ipv4Unicast" in output:
            return True
        return False
    assert _bgp_neighbor_ipv4_af_only() == True
    step("Check if neighbor 192.168.255.254 is enabled for ipv6 address-family only")
    def _bgp_neighbor_ipv6_af_only():
        tgen.gears["r2"].vtysh_cmd(
            "conf t\nrouter bgp\nneighbor 192.168.255.254 remote-as external"
        )
        output = json.loads(tgen.gears["r2"].vtysh_cmd("show bgp summary json"))
        if len(output.keys()) == 1 and "ipv6Unicast" in output:
            return True
        return False
    assert _bgp_neighbor_ipv6_af_only() == True
    step("Check if neighbor 192.168.255.254 is enabled for evpn address-family only")
    def _bgp_neighbor_evpn_af_only():
        tgen.gears["r3"].vtysh_cmd(
            "conf t\nrouter bgp\nneighbor 192.168.255.254 remote-as external"
        )
        output = json.loads(tgen.gears["r3"].vtysh_cmd("show bgp summary json"))
        if len(output.keys()) == 1 and "l2VpnEvpn" in output:
            return True
        return False
    assert _bgp_neighbor_evpn_af_only() == True
    step(
        "Check if neighbor 192.168.255.254 is enabled for ipv4/ipv6 unicast and evpn address-families"
    )
    def _bgp_neighbor_ipv4_ipv6_and_evpn_af():
        tgen.gears["r4"].vtysh_cmd(
            "conf t\nrouter bgp\nneighbor 192.168.255.254 remote-as external"
        )
        output = json.loads(tgen.gears["r4"].vtysh_cmd("show bgp summary json"))
        if (
            len(output.keys()) == 3
            and "ipv4Unicast" in output
            and "ipv6Unicast" in output
            and "l2VpnEvpn" in output
        ):
            return True
        return False
    assert _bgp_neighbor_ipv4_ipv6_and_evpn_af() == True