<commit_before>import pytest
from werkzeug.datastructures import Headers

import config
from skylines import create_api_app
from skylines.app import SkyLines
from tests import setup_dirs


@pytest.fixture(scope="session")
def app():
    """Set up global front-end app for functional tests

    Initialized once per test-run
    """
    app = create_api_app(config.TESTING_CONF_PATH)
    setup_dirs(app)
    return app


@pytest.fixture(scope="function")
def client(app):
    """
    A ``flask.testing.FlaskClient`` for API integration testing.
    """
    assert isinstance(app, SkyLines)
    return app.test_client()


@pytest.yield_fixture(scope="function")
def default_headers():
    headers = Headers()
    headers.add('User-Agent', 'py.test')
    yield headers<commit_msg>tests/api: Simplify 'default_headers' fixture<commit_after>import pytest
from werkzeug.datastructures import Headers

import config
from skylines import create_api_app
from skylines.app import SkyLines
from tests import setup_dirs


@pytest.fixture(scope="session")
def app():
    """Set up global front-end app for functional tests

    Initialized once per test-run
    """
    app = create_api_app(config.TESTING_CONF_PATH)
    setup_dirs(app)
    return app


@pytest.fixture(scope="function")
def client(app):
    """
    A ``flask.testing.FlaskClient`` for API integration testing.
    """
    assert isinstance(app, SkyLines)
    return app.test_client()


@pytest.fixture(scope="function")
def default_headers():
    headers = Headers()
    headers.add('User-Agent', 'py.test')
    return headers
{'fraction_non_alphanumeric': 0.10499683744465528, 'fraction_numerical': 0.0, 'mean_word_length': 4.326599326599327, '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': '6162592', 'n_tokens_mistral': 498, 'n_tokens_neox': 497, 'n_words': 128}