<commit_before><?php
    require_once "../bellite.php";

    setlocale(LC_ALL,'');

    $app = new Bellite();
    $app->on("ready", function() use (&$app){
        $app->ping();
        $app->version();
        $app->perform(142, "echo", array("name" => array(false, true, 42, "value")));

        $app->bindEvent(118, "*");
        $app->unbindEvent(118, "*");

        $app->on('testEvent', function($app, $eobj){
            if (isset($eobj['evt'])){
                $app->perform(0,$eobj['evt']);
            }
            else {
                $app->close();
            }<commit_msg>Changed test from ready event to ready promise<commit_after><?php
    require_once "../bellite.php";

    setlocale(LC_ALL,'');

    $app = new Bellite();
    $app->ready->done(function() use (&$app){
        $app->ping();
        $app->version();
        $app->perform(142, "echo", array("name" => array(false, true, 42, "value")));

        $app->bindEvent(118, "*");
        $app->unbindEvent(118, "*");

        $app->on('testEvent', function($app, $eobj){
            if (isset($eobj['evt'])){
                $app->perform(0,$eobj['evt']);
            }
            else {
                $app->close();
            }
{'fraction_non_alphanumeric': 0.22341302555647155, 'fraction_numerical': 0.01978565539983512, 'mean_word_length': 2.0199004975124377, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 24, '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': '4857745', 'n_tokens_mistral': 402, 'n_tokens_neox': 380, 'n_words': 66}