<commit_before>import unittest

from mock import Mock, patch
from patroni.dcs import Cluster, DCSError, Leader, Member
from patroni.etcd import Client, Etcd
from patroni.exceptions import PostgresException
from patroni.ha import Ha
from test_etcd import socket_getaddrinfo, etcd_read, etcd_write


def true(*args, **kwargs):
    return True


def false(*args, **kwargs):
    return False


def get_cluster(initialize, leader):
    return Cluster(initialize, leader, None, None)


def get_cluster_not_initialized_without_leader():
    return get_cluster(None, None)


def get_cluster_initialized_without_leader():
    return get_cluster(True, None)


def get_cluster_not_initialized_with_leader():
    return get_cluster(False, Leader(0, 0, 0,
                       Member(0, 'leader', 'postgres://replicator:rep-pass@127.0.0.1:5435/postgres',
                              None, None, 28)))
<commit_msg>remove unused function<commit_after>import unittest

from mock import Mock, patch
from patroni.dcs import Cluster, DCSError, Leader, Member
from patroni.etcd import Client, Etcd
from patroni.exceptions import PostgresException
from patroni.ha import Ha
from test_etcd import socket_getaddrinfo, etcd_read, etcd_write


def true(*args, **kwargs):
    return True


def false(*args, **kwargs):
    return False


def get_cluster(initialize, leader):
    return Cluster(initialize, leader, None, None)


def get_cluster_not_initialized_without_leader():
    return get_cluster(None, None)


def get_cluster_initialized_without_leader():
    return get_cluster(True, None)

{'fraction_non_alphanumeric': 0.08328035600762873, 'fraction_numerical': 0.010171646535282899, 'mean_word_length': 4.744525547445256, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 1, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2308765', 'n_tokens_mistral': 495, 'n_tokens_neox': 467, 'n_words': 137}