Fix Vue unit tests

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2021-06-04 20:24:43 +02:00
parent f100fce0da
commit 51106841ab
18 changed files with 283 additions and 66 deletions

View File

@@ -18,3 +18,17 @@ export const loginResponseMock = {
},
},
};
export const resetPasswordResponseMock = {
data: {
resetPassword: {
__typename: "Login",
accessToken: "some access token",
refreshToken: "some refresh token",
user: {
__typename: "User",
id: "1",
},
},
},
};

View File

@@ -113,6 +113,11 @@ export const configMock = {
__typename: "InstanceFeeds",
enabled: false,
},
webPush: {
__typename: "WebPush",
enabled: true,
publicKey: "",
},
},
},
};

View File

@@ -80,6 +80,9 @@ export const eventCommentThreadsMock = {
visibility: "PUBLIC",
totalReplies: 5,
updatedAt: "2020-12-03T09:02:00Z",
inReplyToComment: null,
originComment: null,
replies: [],
actor: {
__typename: "Person",
avatar: {
@@ -94,6 +97,7 @@ export const eventCommentThreadsMock = {
summary: "I am the senate",
},
deletedAt: null,
isAnnouncement: false,
},
{
__typename: "Comment",
@@ -105,6 +109,9 @@ export const eventCommentThreadsMock = {
visibility: "PUBLIC",
totalReplies: 0,
updatedAt: "2020-12-03T11:02:00Z",
inReplyToComment: null,
originComment: null,
replies: [],
actor: {
__typename: "Person",
avatar: {
@@ -119,6 +126,7 @@ export const eventCommentThreadsMock = {
summary: "I am the senate",
},
deletedAt: null,
isAnnouncement: false,
},
],
},
@@ -129,6 +137,7 @@ export const newCommentForEventMock = {
eventId: "1",
text: "my new comment",
inReplyToCommentId: null,
isAnnouncement: false,
};
export const newCommentForEventResponse: DataMock = {
@@ -160,6 +169,7 @@ export const newCommentForEventResponse: DataMock = {
summary: "I am the senate",
},
deletedAt: null,
isAnnouncement: false,
},
},
};