def METHOD_NAME(self):
    """Test that we don't send fee filters to block-relay-only peers and when we're in blocksonly mode."""
    self.log.info("Check that we don't send fee filters to block-relay-only peers.")
    feefilter_peer = self.nodes[0].add_outbound_p2p_connection(FeefilterConn(), p2p_idx=0, connection_type="block-relay-only")
    feefilter_peer.sync_with_ping()
    feefilter_peer.assert_feefilter_received(False)
    self.log.info("Check that we don't send fee filters when in blocksonly mode.")
    self.restart_node(0, ["-blocksonly"])
    feefilter_peer = self.nodes[0].add_p2p_connection(FeefilterConn())
    feefilter_peer.sync_with_ping()
    feefilter_peer.assert_feefilter_received(False)