12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- import {
- EventOrGroupType,
- type Group as GroupType,
- GroupStatus,
- GroupUnresolved,
- IssueCategory,
- IssueType,
- } from 'sentry/types';
- import {Project} from './project';
- export function Group(params: Partial<GroupType> = {}): GroupType {
- const project = Project();
- const unresolvedGroup: GroupUnresolved = {
- activity: [],
- annotations: [],
- assignedTo: null,
- count: '327482',
- culprit: 'fetchData(app/components/group/suggestedOwners/suggestedOwners)',
- firstSeen: '2019-04-05T19:44:05.963Z',
- filtered: null,
- hasSeen: false,
- id: '1',
- isBookmarked: false,
- isPublic: false,
- isSubscribed: false,
- isUnhandled: false,
- issueCategory: IssueCategory.ERROR,
- issueType: IssueType.ERROR,
- lastSeen: '2019-04-11T01:08:59Z',
- level: 'warning',
- logger: null,
- metadata: {function: 'fetchData', type: 'RequestError'},
- numComments: 0,
- participants: [],
- permalink: 'https://foo.io/organizations/foo/issues/1234/',
- platform: 'javascript',
- pluginActions: [],
- pluginContexts: [],
- pluginIssues: [],
- project: TestStubs.Project({
- platform: 'javascript',
- id: project.id,
- slug: project.slug,
- }),
- seenBy: [],
- shareId: '',
- shortId: 'JAVASCRIPT-6QS',
- stats: {
- '24h': [
- [1517281200, 2],
- [1517310000, 1],
- ],
- '30d': [
- [1514764800, 1],
- [1515024000, 122],
- ],
- },
- status: GroupStatus.UNRESOLVED,
- statusDetails: {},
- subscriptionDetails: null,
- title: 'RequestError: GET /issues/ 404',
- type: EventOrGroupType.ERROR,
- userCount: 35097,
- userReportCount: 0,
- };
- return {...unresolvedGroup, ...params} as GroupType;
- }
|