mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Merge branch '5059-groups/5385-webapp-post-in-group' of github.com:Ocelot-Social-Community/Ocelot-Social into 5059-groups/5501-add-group-link-to-posts-in-webapp
This commit is contained in:
commit
d2238269d1
@ -138,6 +138,7 @@ describe('ContributionForm.vue', () => {
|
||||
categoryIds: [],
|
||||
id: null,
|
||||
image: null,
|
||||
groupId: null,
|
||||
},
|
||||
}
|
||||
postTitleInput = wrapper.find('.ds-input')
|
||||
@ -260,6 +261,7 @@ describe('ContributionForm.vue', () => {
|
||||
content: propsData.contribution.content,
|
||||
categoryIds: [],
|
||||
id: propsData.contribution.id,
|
||||
groupId: null,
|
||||
image: {
|
||||
sensitive: false,
|
||||
},
|
||||
|
||||
@ -8,8 +8,8 @@ localVue.filter('date', (d) => d)
|
||||
config.stubs['client-only'] = '<span><slot /></span>'
|
||||
config.stubs['v-popover'] = '<span><slot /></span>'
|
||||
config.stubs['nuxt-link'] = '<span><slot /></span>'
|
||||
// config.stubs['infinite-loading'] = '<span><slot /></span>'
|
||||
// config.stubs['follow-list'] = '<span><slot /></span>'
|
||||
config.stubs['infinite-loading'] = '<span><slot /></span>'
|
||||
config.stubs['follow-list'] = '<span><slot /></span>'
|
||||
|
||||
describe('GroupProfileSlug', () => {
|
||||
let wrapper
|
||||
@ -196,10 +196,11 @@ describe('GroupProfileSlug', () => {
|
||||
})
|
||||
|
||||
describe('mount', () => {
|
||||
Wrapper = () => {
|
||||
Wrapper = (data = () => {}) => {
|
||||
return mount(GroupProfileSlug, {
|
||||
mocks,
|
||||
localVue,
|
||||
data,
|
||||
})
|
||||
}
|
||||
|
||||
@ -213,15 +214,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -365,15 +367,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -477,15 +480,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -589,15 +593,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...yogaPractice,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -705,15 +710,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -821,15 +827,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -937,15 +944,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -1053,15 +1061,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...schoolForCitizens,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -1173,15 +1182,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'owner',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -1292,15 +1302,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'usual',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -1411,15 +1422,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: 'pending',
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@ -1518,15 +1530,16 @@ describe('GroupProfileSlug', () => {
|
||||
'auth/isModerator': () => false,
|
||||
},
|
||||
}
|
||||
wrapper = Wrapper()
|
||||
wrapper.setData({
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
wrapper = Wrapper(() => {
|
||||
return {
|
||||
Group: [
|
||||
{
|
||||
...investigativeJournalism,
|
||||
myRole: null,
|
||||
},
|
||||
],
|
||||
GroupMembers: [peterLustig, jennyRostock, bobDerBaumeister, huey],
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
@ -56,6 +56,10 @@ describe('PostSlug', () => {
|
||||
},
|
||||
$route: {
|
||||
hash: '',
|
||||
params: {
|
||||
slug: 'slug',
|
||||
id: 'id',
|
||||
},
|
||||
},
|
||||
// If you are mocking the router, then don't use VueRouter with localVue: https://vue-test-utils.vuejs.org/guides/using-with-vue-router.html
|
||||
$router: {
|
||||
|
||||
@ -11,6 +11,11 @@ describe('create.vue', () => {
|
||||
$env: {
|
||||
CATEGORIES_ACTIVE: false,
|
||||
},
|
||||
$route: {
|
||||
query: {
|
||||
groupId: null,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
describe('mount', () => {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user