mirror of
https://github.com/IT4Change/gradido.git
synced 2026-04-06 01:25:28 +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)
|
expect(wrapper.find('div.contribution-link').exists()).toBe(true)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('emits toggle::collapse new Contribution', async () => {
|
describe('collapse open new Contribution', () => {
|
||||||
wrapper.vm.editContributionLinkData()
|
beforeEach(() => {
|
||||||
expect(wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')).toBeTruthy()
|
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 () => {
|
describe('collapse close Contribution Form', () => {
|
||||||
wrapper.vm.closeContributionForm()
|
beforeEach(() => {
|
||||||
expect(wrapper.vm.$root.$emit('bv::toggle::collapse', 'newContribution')).toBeTruthy()
|
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: 'confirm', label: this.$t('save') },
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
{ key: 'state', label: 'state' },
|
|
||||||
{ key: 'firstName', label: this.$t('firstname') },
|
{ key: 'firstName', label: this.$t('firstname') },
|
||||||
{ key: 'lastName', label: this.$t('lastname') },
|
{ key: 'lastName', label: this.$t('lastname') },
|
||||||
{
|
{
|
||||||
@ -233,6 +232,13 @@ export default {
|
|||||||
return this.$d(new Date(value), 'short')
|
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') },
|
{ key: 'chatCreation', label: this.$t('chat') },
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
@ -273,6 +279,7 @@ export default {
|
|||||||
],
|
],
|
||||||
[],
|
[],
|
||||||
[
|
[
|
||||||
|
{ key: 'state', label: 'state' },
|
||||||
{ key: 'firstName', label: this.$t('firstname') },
|
{ key: 'firstName', label: this.$t('firstname') },
|
||||||
{ key: 'lastName', label: this.$t('lastname') },
|
{ key: 'lastName', label: this.$t('lastname') },
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user