<commit_before>set_global('$', global.make_zjquery());
set_global('i18n', global.stub_i18n);

zrequire('localstorage');
zrequire('drafts');
set_global('XDate', zrequire('XDate', 'xdate'));
zrequire('timerender');
set_global('Handlebars', global.make_handlebars());
zrequire('util');
zrequire('stream_color');
zrequire('colorspace');

let ls_container = {};
const noop = function () { return; };

set_global('localStorage', {
    getItem: function (key) {
        return ls_container[key];
    },
    setItem: function (key, val) {
        ls_container[key] = val;
    },
    removeItem: function (key) {
        delete ls_container[key];
    },
    clear: function () {
        ls_container = {};
    },
});
set_global('compose', {});
set_global('compose_state', {});
set_global('stream_data', {
    get_color: function () {
        return '#FFFFFF';
    },
});
set_global('blueslip', {});
set_global('people', {
    // Mocking get_by_email function, here we are
    // just returning string before `@` in email
    get_by_email: function (email) {
        return {
            full_name: email.split('@')[0],<commit_msg>tests: Convert ls_container from object to Map.<commit_after>set_global('$', global.make_zjquery());
set_global('i18n', global.stub_i18n);

zrequire('localstorage');
zrequire('drafts');
set_global('XDate', zrequire('XDate', 'xdate'));
zrequire('timerender');
set_global('Handlebars', global.make_handlebars());
zrequire('util');
zrequire('stream_color');
zrequire('colorspace');

const ls_container = new Map();
const noop = function () { return; };

set_global('localStorage', {
    getItem: function (key) {
        return ls_container.get(key);
    },
    setItem: function (key, val) {
        ls_container.set(key, val);
    },
    removeItem: function (key) {
        ls_container.delete(key);
    },
    clear: function () {
        ls_container.clear();
    },
});
set_global('compose', {});
set_global('compose_state', {});
set_global('stream_data', {
    get_color: function () {
        return '#FFFFFF';
    },
});
set_global('blueslip', {});
set_global('people', {
    // Mocking get_by_email function, here we are
    // just returning string before `@` in email
    get_by_email: function (email) {
        return {
            full_name: email.split('@')[0],
{'fraction_non_alphanumeric': 0.17647058823529413, 'fraction_numerical': 0.004357298474945534, 'mean_word_length': 4.024070021881838, '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': '5881877', 'n_tokens_mistral': 760, 'n_tokens_neox': 744, 'n_words': 142}