mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
test fix for GddAmount.vue
This commit is contained in:
parent
544509446a
commit
3c3a1f89ad
@ -25,7 +25,7 @@ describe('CommunityMember', () => {
|
||||
wrapper = Wrapper()
|
||||
})
|
||||
|
||||
it('renders the component transaction-slot-send', () => {
|
||||
it('renders the component community-member', () => {
|
||||
expect(wrapper.find('div.community-member').exists()).toBe(true)
|
||||
})
|
||||
})
|
||||
|
||||
@ -0,0 +1,42 @@
|
||||
import { mount } from '@vue/test-utils'
|
||||
import GddAmount from './GddAmount'
|
||||
|
||||
const localVue = global.localVue
|
||||
|
||||
const state = {
|
||||
language: 'en',
|
||||
}
|
||||
|
||||
const mocks = {
|
||||
$store: {
|
||||
state,
|
||||
},
|
||||
$i18n: {
|
||||
locale: 'en',
|
||||
},
|
||||
$t: jest.fn((t) => t),
|
||||
}
|
||||
|
||||
const propsData = {
|
||||
path: 'string',
|
||||
balance: 123.45,
|
||||
badgeShow: false,
|
||||
showStatus: false,
|
||||
}
|
||||
|
||||
describe('GddAmount', () => {
|
||||
let wrapper
|
||||
|
||||
const Wrapper = () => {
|
||||
return mount(GddAmount, { localVue, mocks, propsData })
|
||||
}
|
||||
describe('mount', () => {
|
||||
beforeEach(() => {
|
||||
wrapper = Wrapper()
|
||||
})
|
||||
|
||||
it('renders the component gdd-amount', () => {
|
||||
expect(wrapper.find('div.gdd-amount').exists()).toBe(true)
|
||||
})
|
||||
})
|
||||
})
|
||||
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="translucent-color-opacity">
|
||||
<div class="gdd-amount translucent-color-opacity">
|
||||
<div class="text-center">
|
||||
<b-badge
|
||||
v-if="badgeShow"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user