<commit_before><?php
require_once __DIR__ . '/config.php'; // (`once` because it may required in skip when we run phpt)

// PHP settings
error_reporting(E_ALL ^ E_DEPRECATED);
ini_set('memory_limit', '1024M');
assert_options(ASSERT_ACTIVE, 1);
assert_options(ASSERT_WARNING, 1);
assert_options(ASSERT_BAIL, 0);

// Swoole settings
swoole_async_set([
    'socket_dontwait' => 1,
    'disable_dns_cache' => true,
    'dns_lookup_random' => true,
]);
Co::set([
    'socket_timeout' => 5
]);
if (empty(getenv('SWOOLE_DEBUG'))) {
    Co::set([
        'log_level' => SWOOLE_LOG_INFO,
        'trace_flags' => 0,
    ]);
}

// Components
(function () {
    require __DIR__ . '/lib/vendor/autoload.php';

    class ProcessManager extends SwooleTest\ProcessManager{}
    class ServerManager extends SwooleTest\ServerManager{}
    class RandStr extends SwooleTest\RandStr{}
    class TcpStat extends SwooleTest\TcpStat{}

    class Assert extends \Swoole\Assert
    {
        protected static $throwException = false;
    }
})();<commit_msg>revert<commit_after><?php
require_once __DIR__ . '/config.php'; // (`once` because it may required in skip when we run phpt)

// PHP settings
error_reporting(E_ALL ^ E_DEPRECATED);
ini_set('memory_limit', '1024M');
assert_options(ASSERT_ACTIVE, 1);
assert_options(ASSERT_WARNING, 1);
assert_options(ASSERT_BAIL, 0);

// Swoole settings
swoole_async_set([
    'socket_dontwait' => 1,
    'disable_dns_cache' => true,
    'dns_lookup_random' => true,
]);
Co::set([
    'socket_timeout' => 5
]);
if (empty(getenv('SWOOLE_DEBUG'))) {
    Co::set([
        'log_level' => SWOOLE_LOG_INFO,
        'trace_flags' => 0,
    ]);
}

// Components
(function () {
    require __DIR__ . '/lib/vendor/autoload.php';

    class_alias(SwooleTest\ProcessManager::class, ProcessManager::class);
    class_alias(SwooleTest\ServerManager::class, ServerManager::class);
    class_alias(SwooleTest\RandStr::class, RandStr::class);
    class_alias(SwooleTest\TcpStat::class, TcpStat::class);

    class Assert extends \Swoole\Assert
    {
        protected static $throwException = false;
    }
})();
{'fraction_non_alphanumeric': 0.14509246088193456, 'fraction_numerical': 0.00948316737790422, 'mean_word_length': 4.235732009925559, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 15, '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': '5188400', 'n_tokens_mistral': 752, 'n_tokens_neox': 727, 'n_words': 142}