<commit_before>from __future__ import absolute_import
from __future__ import unicode_literals

import os
import subprocess

import mock
import pytest


@pytest.yield_fixture
def in_tmpdir(tmpdir):
    pwd = <PASSWORD>()
    os.chdir(tmpdir.strpath)
    try:
        yield
    finally:
        os.chdir(pwd)


@pytest.yield_fixture
def check_call_mock():
    with mock.patch.object(subprocess, 'check_call') as mocked:
        yield mocked<commit_msg>Replace deprecated yield_fixture with fixture<commit_after>from __future__ import absolute_import
from __future__ import unicode_literals

import os
import subprocess

import mock
import pytest


@pytest.fixture
def in_tmpdir(tmpdir):
    pwd = <PASSWORD>()
    os.chdir(tmpdir.strpath)
    try:
        yield
    finally:
        os.chdir(pwd)


@pytest.fixture
def check_call_mock():
    with mock.patch.object(subprocess, 'check_call') as mocked:
        yield mocked
{'fraction_non_alphanumeric': 0.07608695652173914, 'fraction_numerical': 0.0, 'mean_word_length': 3.8219895287958114, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '2178158', 'n_tokens_mistral': 311, 'n_tokens_neox': 309, 'n_words': 75}