<commit_before>#include "stringhelpersfortests.h"

QString getRandomString(int length, bool exactSize) {
    if (length <= 0) { return QString(); }
    
    QByteArray qbr;
    qbr.reserve(length);
    const char chars[] = "/!@#$% ^&*()_+=|";
    int charsLength = sizeof(chars);
    while (length--) {
        qbr.append('a' + qrand()%26);

        if (qrand() % 3 == 0) {
            qbr.append(chars[qrand() % charsLength]);
        }
<commit_msg>Yet another fix for tests<commit_after>#include "stringhelpersfortests.h"

QString getRandomString(int length, bool exactSize) {
    if (length <= 0) { return QString(); }
    
    QByteArray qbr;
    qbr.reserve(length);
    const char chars[] = "/!@#$% ^&*()_+=|";
    int charsLength = sizeof(chars) - 1;

    while (length--) {
        qbr.append('a' + qrand()%26);

        if (qrand() % 3 == 0) {
            qbr.append(chars[qrand() % charsLength]);
        }

{'fraction_non_alphanumeric': 0.17993456924754633, 'fraction_numerical': 0.011995637949836423, 'mean_word_length': 2.6867469879518073, 'pattern_counts': {'":': 0, '<': 5, '<?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': '4262045', 'n_tokens_mistral': 335, 'n_tokens_neox': 319, 'n_words': 67}