Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/issues/show/components/incidents/mock_data.js')
-rw-r--r--spec/frontend/issues/show/components/incidents/mock_data.js72
1 files changed, 72 insertions, 0 deletions
diff --git a/spec/frontend/issues/show/components/incidents/mock_data.js b/spec/frontend/issues/show/components/incidents/mock_data.js
new file mode 100644
index 00000000000..b5346a6089a
--- /dev/null
+++ b/spec/frontend/issues/show/components/incidents/mock_data.js
@@ -0,0 +1,72 @@
+export const mockEvents = [
+ {
+ action: 'comment',
+ author: {
+ __typename: 'UserCore',
+ id: 'gid://gitlab/User/1',
+ name: 'Administrator',
+ username: 'root',
+ },
+ createdAt: '2022-03-22T15:59:08Z',
+ id: 'gid://gitlab/IncidentManagement::TimelineEvent/132',
+ note: 'Dummy event 1',
+ noteHtml: '<p>Dummy event 1</p>',
+ occurredAt: '2022-03-22T15:59:00Z',
+ updatedAt: '2022-03-22T15:59:08Z',
+ __typename: 'TimelineEventType',
+ },
+ {
+ action: 'comment',
+ author: {
+ __typename: 'UserCore',
+ id: 'gid://gitlab/User/1',
+ name: 'Administrator',
+ username: 'root',
+ },
+ createdAt: '2022-03-23T14:57:08Z',
+ id: 'gid://gitlab/IncidentManagement::TimelineEvent/131',
+ note: 'Dummy event 2',
+ noteHtml: '<p>Dummy event 2</p>',
+ occurredAt: '2022-03-23T14:57:00Z',
+ updatedAt: '2022-03-23T14:57:08Z',
+ __typename: 'TimelineEventType',
+ },
+ {
+ action: 'comment',
+ author: {
+ __typename: 'UserCore',
+ id: 'gid://gitlab/User/1',
+ name: 'Administrator',
+ username: 'root',
+ },
+ createdAt: '2022-03-23T15:59:08Z',
+ id: 'gid://gitlab/IncidentManagement::TimelineEvent/132',
+ note: 'Dummy event 3',
+ noteHtml: '<p>Dummy event 3</p>',
+ occurredAt: '2022-03-23T15:59:00Z',
+ updatedAt: '2022-03-23T15:59:08Z',
+ __typename: 'TimelineEventType',
+ },
+];
+
+export const timelineEventsQueryListResponse = {
+ data: {
+ project: {
+ id: 'gid://gitlab/Project/8',
+ incidentManagementTimelineEvents: {
+ nodes: mockEvents,
+ },
+ },
+ },
+};
+
+export const timelineEventsQueryEmptyResponse = {
+ data: {
+ project: {
+ id: 'gid://gitlab/Project/8',
+ incidentManagementTimelineEvents: {
+ nodes: [],
+ },
+ },
+ },
+};