def METHOD_NAME(
    generated_docs, service_name, client, paginator_names
):
    ref_lines = [
        '==========',
        'Paginators',
        '==========',
        'The available paginators are:',
    ]
    for paginator_name in paginator_names:
        ref_lines.append(f'  {service_name}/paginator/{paginator_name}')
    for paginator_name in paginator_names:
        _assert_contains_lines_in_order(
            [
                '.. py:class:: {}.Paginator.{}'.format(
                    client.__class__.__name__, paginator_name
                ),
                '  .. py:method:: paginate(',
            ],
            get_nested_file_contents(
                service_name, 'paginator', paginator_name
            ),
        )
    _assert_contains_lines_in_order(ref_lines, generated_docs)