<commit_before>import Vue from 'vue'
import { shallowMount, createLocalVue } from '@vue/test-utils'
import Vuex from 'vuex'
import i18n from '../../../src/lib/i18n'
import ShowInfosButton from '../../../src/components/widgets/ShowInfosButton'

const localVue = createLocalVue()

localVue.use(Vuex)

describe('ShowInfosButton', () => {
  let actions
  let state
  let store
  let mutations
  let getters
  let wrapper

  beforeEach(() => {
    state = {
      isShowInfos: true
    }

    mutations = {
      toggleState (state) {
        state.isShowInfos = !state.isShowInfos
      }
    }

    actions = {
      showInfos: jest.fn(),
      hideInfos: jest.fn()
    }

    getters = {
      isShowInfos: state => state.isShowInfos
    }

    store = new Vuex.Store({
      strict: true,
      modules: {
        tasks: {
          actions,<commit_msg>[qa] fix tests/unit/widgets/showinfosbutton.spec.js<commit_after>import Vue from 'vue'
import { shallowMount, createLocalVue } from '@vue/test-utils'
import Vuex from 'vuex'
import i18n from '../../../src/lib/i18n'
import ShowInfosButton from '../../../src/components/widgets/ShowInfosButton'

const localVue = createLocalVue()

localVue.use(Vuex)

describe('ShowInfosButton', () => {
  let actions
  let state
  let store
  let mutations
  let getters
  let wrapper

  beforeEach(() => {
    state = {
      isShowInfos: true,
      isShowInfosBreakdown: true
    }

    mutations = {
      toggleState (state) {
        state.isShowInfos = !state.isShowInfos
      }
    }

    actions = {
      showInfos: jest.fn(),
      hideInfos: jest.fn()
    }

    getters = {
      isShowInfos: state => state.isShowInfos,
      isShowInfosBreakdown: state => state.isShowInfosBreakdown
    }

    store = new Vuex.Store({
      strict: true,
      modules: {
        tasks: {
          actions,
{'fraction_non_alphanumeric': 0.1249321021184139, 'fraction_numerical': 0.0043454644215100485, 'mean_word_length': 2.4429906542056075, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 10, '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': '6334193', 'n_tokens_mistral': 636, 'n_tokens_neox': 617, 'n_words': 134}