mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
test coverage by 95.32%
This commit is contained in:
parent
b2c8f8ac9e
commit
07c50c97d8
@ -42,14 +42,32 @@ describe('ContributionLink', () => {
|
||||
expect(wrapper.find('div.contribution-link').exists()).toBe(true)
|
||||
})
|
||||
|
||||
it('emits toggle::collapse new Contribution', async () => {
|
||||
wrapper.vm.editContributionLinkData()
|
||||
expect(wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')).toBeTruthy()
|
||||
describe('collapse open new Contribution', () => {
|
||||
beforeEach(() => {
|
||||
wrapper.vm.editContributionLinkData()
|
||||
})
|
||||
it('emits toggle::collapse new Contribution', () => {
|
||||
expect(wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')).toBeTruthy()
|
||||
})
|
||||
it('has collapse visible true', () => {
|
||||
expect(wrapper.vm.visible).toBe(true)
|
||||
})
|
||||
})
|
||||
|
||||
it('emits toggle::collapse close Contribution-Form ', async () => {
|
||||
wrapper.vm.closeContributionForm()
|
||||
expect(wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')).toBeTruthy()
|
||||
describe('collapse close Contribution Form', () => {
|
||||
beforeEach(() => {
|
||||
wrapper.setData({ visible: true })
|
||||
wrapper.vm.closeContributionForm()
|
||||
})
|
||||
|
||||
it('has collapse visible false', async () => {
|
||||
await wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')
|
||||
expect(wrapper.vm.visible).toBe(false)
|
||||
})
|
||||
|
||||
it('has editContributionLink false', () => {
|
||||
expect(wrapper.vm.editContributionLink).toBe(false)
|
||||
})
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
@ -1,10 +0,0 @@
|
||||
import gql from 'graphql-tag'
|
||||
|
||||
export const listUnconfirmedContributions = gql`
|
||||
query {
|
||||
listUnconfirmedContributions {
|
||||
id
|
||||
state
|
||||
}
|
||||
}
|
||||
`
|
||||
@ -208,7 +208,6 @@ export default {
|
||||
{ key: 'confirm', label: this.$t('save') },
|
||||
],
|
||||
[
|
||||
{ key: 'state', label: 'state' },
|
||||
{ key: 'firstName', label: this.$t('firstname') },
|
||||
{ key: 'lastName', label: this.$t('lastname') },
|
||||
{
|
||||
@ -233,6 +232,13 @@ export default {
|
||||
return this.$d(new Date(value), 'short')
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'confirmedAt',
|
||||
label: this.$t('contributions.confirms'),
|
||||
formatter: (value) => {
|
||||
return this.$d(new Date(value), 'short')
|
||||
},
|
||||
},
|
||||
{ key: 'chatCreation', label: this.$t('chat') },
|
||||
],
|
||||
[
|
||||
@ -273,6 +279,7 @@ export default {
|
||||
],
|
||||
[],
|
||||
[
|
||||
{ key: 'state', label: 'state' },
|
||||
{ key: 'firstName', label: this.$t('firstname') },
|
||||
{ key: 'lastName', label: this.$t('lastname') },
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user