<commit_before>import test from 'ava';
import '~client-test/browser';
import { fromJS } from 'immutable';
import { render } from 'react-testing-library';
import { createMockStore } from 'redux-test-utils';
import React from 'react';
import Root from '~client/containers/Root';

const getContainer = (customProps = {}, customState = null) => {
    let state = fromJS({
        user: {
            uid: 1
        },
        loadingApi: false,
        errorMsg: [],
        loginForm: {
            inputStep: 0,
            visible: false,
            active: false,
            values: []
        },
        edit: {
            requestList: []
        }
    });

    if (customState) {
        state = customState(state);
    }

    const store = createMockStore(state);

    const props = {
        store,
        ...customProps
    };

    const utils = render(
        <Root {...props} />
    );

    return { store, ...utils };<commit_msg>Added properties to state in <Root /> test to get rid of missing prop warnings in test<commit_after>import test from 'ava';
import '~client-test/browser';
import { fromJS } from 'immutable';
import { render } from 'react-testing-library';
import { createMockStore } from 'redux-test-utils';
import React from 'react';
import Root from '~client/containers/Root';

const getContainer = (customProps = {}, customState = null) => {
    let state = fromJS({
        user: {
            uid: 1
        },
        currentPage: 'general',
        loading: false,
        loadingApi: false,
        errorMsg: [],
        loginForm: {
            inputStep: 0,
            visible: false,
            active: false,
            values: []
        },
        modalDialog: {
            active: false,
            visible: false,
            loading: false
        },
        edit: {
            requestList: []
        }
    });

    if (customState) {
        state = customState(state);
    }

    const store = createMockStore(state);

    const props = {
        store,
        ...customProps
    };

    const utils = render(
        <Root {...props} />
    );

    return { store, ...utils };
{'fraction_non_alphanumeric': 0.12682010333489901, 'fraction_numerical': 0.0018788163457022077, 'mean_word_length': 1.7698309492847855, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 8, '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': '917093', 'n_tokens_mistral': 598, 'n_tokens_neox': 587, 'n_words': 164}