<commit_before>from testtools.matchers import (
    AfterPreprocessing, Equals, IsInstance, MatchesAll, MatchesStructure,
    Mismatch
)
from testtools.twistedsupport import failed


class HasHeader(Equals):
    def __init__(self, key, values):
        """
        Checks for a certain header with certain values in the headers of a
        response or request. Note that headers may be specified multiple times
        and that the order of repeated headers is important.

        :param str key:
            The header name/key.<commit_msg>matchers: Remove unused import<commit_after>from testtools.matchers import (
    AfterPreprocessing, Equals, IsInstance, MatchesAll, MatchesStructure,
    Mismatch
)


class HasHeader(Equals):
    def __init__(self, key, values):
        """
        Checks for a certain header with certain values in the headers of a
        response or request. Note that headers may be specified multiple times
        and that the order of repeated headers is important.

        :param str key:
            The header name/key.
{'fraction_non_alphanumeric': 0.05487228003784295, 'fraction_numerical': 0.0, 'mean_word_length': 2.9924528301886792, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '4118321', 'n_tokens_mistral': 266, 'n_tokens_neox': 260, 'n_words': 114}