<commit_before>import os
import sys
import json
from unittest import mock

import pytest
from tornado.web import HTTPError
from tornado.httputil import HTTPServerRequest
from tornado.http1connection import HTTP1ConnectionParameters

import waterbutler
from waterbutler.server.app import make_app
from waterbutler.core.path import WaterButlerPath
from waterbutler.tasks.exceptions import WaitTimeOutError
from waterbutler.server.api.v1.provider import ProviderHandler
from tests.utils import (MockProvider, MockFileMetadata, MockFolderMetadata,
                         MockFileRevisionMetadata, MockCoroutine, MockRequestBody, MockStream)


@pytest.fixture
def http_request():
    mocked_http_request = HTTPServerRequest(
        uri='/v1/resources/test/providers/test/path/mock',
        method='GET'
    )
    mocked_http_request.headers['User-Agent'] = 'test'
    mocked_http_request.connection = HTTP1ConnectionParameters()
    mocked_http_request.connection.set_close_callback = mock.Mock()
    mocked_http_request.request_time = mock.Mock(return_value=10)
    mocked_http_request.body = MockRequestBody()
    return mocked_http_request


@pytest.fixture
def mock_stream():
    return MockStream()


@pytest.fixture
def mock_partial_stream():
    stream = MockStream()<commit_msg>remove unused import from v1 test fixtures<commit_after>import os
import sys
import json
from unittest import mock

import pytest
from tornado.web import HTTPError
from tornado.httputil import HTTPServerRequest
from tornado.http1connection import HTTP1ConnectionParameters

import waterbutler
from waterbutler.core.path import WaterButlerPath
from waterbutler.tasks.exceptions import WaitTimeOutError
from waterbutler.server.api.v1.provider import ProviderHandler
from tests.utils import (MockProvider, MockFileMetadata, MockFolderMetadata,
                         MockFileRevisionMetadata, MockCoroutine, MockRequestBody, MockStream)


@pytest.fixture
def http_request():
    mocked_http_request = HTTPServerRequest(
        uri='/v1/resources/test/providers/test/path/mock',
        method='GET'
    )
    mocked_http_request.headers['User-Agent'] = 'test'
    mocked_http_request.connection = HTTP1ConnectionParameters()
    mocked_http_request.connection.set_close_callback = mock.Mock()
    mocked_http_request.request_time = mock.Mock(return_value=10)
    mocked_http_request.body = MockRequestBody()
    return mocked_http_request


@pytest.fixture
def mock_stream():
    return MockStream()


@pytest.fixture
def mock_partial_stream():
    stream = MockStream()
{'fraction_non_alphanumeric': 0.07045009784735812, 'fraction_numerical': 0.005870841487279843, 'mean_word_length': 5.07125890736342, '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': '4716417', 'n_tokens_mistral': 740, 'n_tokens_neox': 736, 'n_words': 163}