From 1b0c062966d6b1050fba13fb9ae0fd8532c5bc48 Mon Sep 17 00:00:00 2001 From: Julia Bardi <90178898+juliaElastic@users.noreply.github.com> Date: Wed, 17 Nov 2021 11:14:37 +0100 Subject: [PATCH 1/5] [Fleet] remove internal params when querying registry (#118693) * removed internal param * fixed tests * fixed tests --- .../plugins/fleet/server/services/epm/archive/validation.ts | 1 - x-pack/plugins/fleet/server/services/epm/packages/get.ts | 6 +----- .../plugins/fleet/server/services/epm/packages/install.ts | 3 +-- x-pack/plugins/fleet/server/services/epm/registry/index.ts | 4 +--- .../apis/epm/__snapshots__/install_by_upload.snap | 1 - .../fleet_api_integration/apis/epm/install_remove_assets.ts | 1 - x-pack/test/fleet_api_integration/apis/epm/update_assets.ts | 1 - 7 files changed, 3 insertions(+), 14 deletions(-) diff --git a/x-pack/plugins/fleet/server/services/epm/archive/validation.ts b/x-pack/plugins/fleet/server/services/epm/archive/validation.ts index a46a26738bdab..8d20d88c7a9aa 100644 --- a/x-pack/plugins/fleet/server/services/epm/archive/validation.ts +++ b/x-pack/plugins/fleet/server/services/epm/archive/validation.ts @@ -61,7 +61,6 @@ const optionalArchivePackageProps: readonly OptionalPackageProp[] = [ 'readme', 'assets', 'data_streams', - 'internal', 'license', 'type', 'categories', diff --git a/x-pack/plugins/fleet/server/services/epm/packages/get.ts b/x-pack/plugins/fleet/server/services/epm/packages/get.ts index b6a1850fed5b8..83bb8125e077e 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/get.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/get.ts @@ -54,15 +54,11 @@ export async function getPackages( }); // get the installed packages const packageSavedObjects = await getPackageSavedObjects(savedObjectsClient); - // filter out any internal packages - const savedObjectsVisible = packageSavedObjects.saved_objects.filter( - (o) => !o.attributes.internal - ); const packageList = registryItems .map((item) => createInstallableFrom( item, - savedObjectsVisible.find(({ id }) => id === item.name) + packageSavedObjects.saved_objects.find(({ id }) => id === item.name) ) ) .sort(sortByName); diff --git a/x-pack/plugins/fleet/server/services/epm/packages/install.ts b/x-pack/plugins/fleet/server/services/epm/packages/install.ts index 42f4663dc21e3..5b86c944feb39 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/install.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/install.ts @@ -530,7 +530,7 @@ export async function createInstallation(options: { installSource: InstallSource; }) { const { savedObjectsClient, packageInfo, installSource } = options; - const { internal = false, name: pkgName, version: pkgVersion } = packageInfo; + const { name: pkgName, version: pkgVersion } = packageInfo; const removable = !isUnremovablePackage(pkgName); const toSaveESIndexPatterns = generateESIndexPatterns(packageInfo.data_streams); @@ -549,7 +549,6 @@ export async function createInstallation(options: { es_index_patterns: toSaveESIndexPatterns, name: pkgName, version: pkgVersion, - internal, removable, install_version: pkgVersion, install_status: 'installing', diff --git a/x-pack/plugins/fleet/server/services/epm/registry/index.ts b/x-pack/plugins/fleet/server/services/epm/registry/index.ts index 85a52763b7fb7..ff829eca5ec18 100644 --- a/x-pack/plugins/fleet/server/services/epm/registry/index.ts +++ b/x-pack/plugins/fleet/server/services/epm/registry/index.ts @@ -96,9 +96,7 @@ export async function fetchList(params?: SearchParams): Promise { const registryUrl = getRegistryUrl(); - const url = new URL( - `${registryUrl}/search?package=${packageName}&internal=true&experimental=true` - ); + const url = new URL(`${registryUrl}/search?package=${packageName}&experimental=true`); setKibanaVersion(url); diff --git a/x-pack/test/fleet_api_integration/apis/epm/__snapshots__/install_by_upload.snap b/x-pack/test/fleet_api_integration/apis/epm/__snapshots__/install_by_upload.snap index 98dc4c2630743..04d189b5d59b2 100644 --- a/x-pack/test/fleet_api_integration/apis/epm/__snapshots__/install_by_upload.snap +++ b/x-pack/test/fleet_api_integration/apis/epm/__snapshots__/install_by_upload.snap @@ -446,7 +446,6 @@ Object { "type": "search", }, ], - "internal": false, "keep_policies_up_to_date": false, "name": "apache", "package_assets": Array [ diff --git a/x-pack/test/fleet_api_integration/apis/epm/install_remove_assets.ts b/x-pack/test/fleet_api_integration/apis/epm/install_remove_assets.ts index 699b60a14b911..f3f036107fc22 100644 --- a/x-pack/test/fleet_api_integration/apis/epm/install_remove_assets.ts +++ b/x-pack/test/fleet_api_integration/apis/epm/install_remove_assets.ts @@ -668,7 +668,6 @@ const expectAssetsInstalled = ({ ], name: 'all_assets', version: '0.1.0', - internal: false, removable: true, install_version: '0.1.0', install_status: 'installed', diff --git a/x-pack/test/fleet_api_integration/apis/epm/update_assets.ts b/x-pack/test/fleet_api_integration/apis/epm/update_assets.ts index 4ae42ce179219..d55f6aad53aa2 100644 --- a/x-pack/test/fleet_api_integration/apis/epm/update_assets.ts +++ b/x-pack/test/fleet_api_integration/apis/epm/update_assets.ts @@ -457,7 +457,6 @@ export default function (providerContext: FtrProviderContext) { ], name: 'all_assets', version: '0.2.0', - internal: false, removable: true, install_version: '0.2.0', install_status: 'installed', From dfbe896f4bb6547e696ae8ca1cb4e3b90931318a Mon Sep 17 00:00:00 2001 From: Dmitry Tomashevich <39378793+Dmitriynj@users.noreply.github.com> Date: Wed, 17 Nov 2021 14:25:35 +0300 Subject: [PATCH 2/5] [Discover] Fix saved search embeddable pagination (#117507) * [Discover] fix saved search embeddable pagination * [Discover] fix linting error Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> --- .../components/pager/tool_bar_pagination.tsx | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/plugins/discover/public/components/doc_table/components/pager/tool_bar_pagination.tsx b/src/plugins/discover/public/components/doc_table/components/pager/tool_bar_pagination.tsx index ccdb620e0ab85..ae5d2fa32ea65 100644 --- a/src/plugins/discover/public/components/doc_table/components/pager/tool_bar_pagination.tsx +++ b/src/plugins/discover/public/components/doc_table/components/pager/tool_bar_pagination.tsx @@ -18,6 +18,7 @@ import { } from '@elastic/eui'; import { FormattedMessage } from '@kbn/i18n/react'; import { i18n } from '@kbn/i18n'; +import { euiLightVars } from '@kbn/ui-shared-deps-src/theme'; interface ToolBarPaginationProps { pageSize: number; @@ -27,6 +28,11 @@ interface ToolBarPaginationProps { onPageSizeChange: (size: number) => void; } +const TOOL_BAR_PAGINATION_STYLES = { + marginLeft: 'auto', + marginRight: euiLightVars.euiSizeL, +}; + export const ToolBarPagination = ({ pageSize, pageCount, @@ -61,12 +67,7 @@ export const ToolBarPagination = ({ )); return ( - + - + Date: Wed, 17 Nov 2021 07:02:24 -0500 Subject: [PATCH 3/5] [Security Solution] Enhancement endpoint flyout UI fixes (#117987) * initial UI changes for font size and deprecated dependency * remove euitext wrapper * Remove unused dependency * Remove import * Add text break word * inline policy, version and icon * Allign icon in the out_of_date component * Remove unncessary wrapper * Replace style attributes with className Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> --- .../view/components/out_of_date.tsx | 10 +- .../components/endpoint_details_tabs.tsx | 3 +- .../view/details/components/flyout_header.tsx | 2 +- .../view/details/endpoint_details_content.tsx | 193 ++++++++++-------- 4 files changed, 122 insertions(+), 86 deletions(-) diff --git a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/out_of_date.tsx b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/out_of_date.tsx index 0546c57b38268..d65cfc0cd397b 100644 --- a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/out_of_date.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/out_of_date.tsx @@ -11,8 +11,14 @@ import { FormattedMessage } from '@kbn/i18n/react'; export const OutOfDate = React.memo<{ style?: React.CSSProperties }>(({ style, ...otherProps }) => { return ( - - + + ); diff --git a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/endpoint_details_tabs.tsx b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/endpoint_details_tabs.tsx index adae21b55a637..4c0e1b799a6be 100644 --- a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/endpoint_details_tabs.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/endpoint_details_tabs.tsx @@ -6,7 +6,7 @@ */ import React, { memo, useMemo } from 'react'; -import { EuiTab, EuiTabs, EuiFlyoutBody, EuiSpacer } from '@elastic/eui'; +import { EuiTab, EuiTabs, EuiFlyoutBody } from '@elastic/eui'; import { EndpointIndexUIQueryParams } from '../../../types'; import { EndpointDetailsFlyoutHeader } from './flyout_header'; @@ -68,7 +68,6 @@ export const EndpointDetailsFlyoutTabs = memo( return ( <> - {renderTabs} diff --git a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/flyout_header.tsx b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/flyout_header.tsx index f791c0d6adf17..3c8cdf6bf3183 100644 --- a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/flyout_header.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/details/components/flyout_header.tsx @@ -28,7 +28,7 @@ export const EndpointDetailsFlyoutHeader = memo( ) : ( - +

{ + return ( + +
{children}
+
+ ); +}; + export const EndpointDetailsContent = memo( ({ details, @@ -70,83 +77,96 @@ export const EndpointDetailsContent = memo( const detailsResults = useMemo(() => { return [ { - title: i18n.translate('xpack.securitySolution.endpoint.details.os', { - defaultMessage: 'OS', - }), - description: {details.host.os.full}, + title: ( + + + + ), + description: {details.host.os.full}, }, { - title: i18n.translate('xpack.securitySolution.endpoint.details.agentStatus', { - defaultMessage: 'Agent Status', - }), + title: ( + + + + ), description: , }, { - title: i18n.translate('xpack.securitySolution.endpoint.details.lastSeen', { - defaultMessage: 'Last Seen', - }), + title: ( + + + + ), description: ( - - {' '} - + + ), }, { - title: i18n.translate('xpack.securitySolution.endpoint.details.policy', { - defaultMessage: 'Policy', - }), + title: ( + + + + ), description: ( - - - - - {details.Endpoint.policy.applied.name} - + + + {details.Endpoint.policy.applied.name} + + {details.Endpoint.policy.applied.endpoint_policy_version && ( + + - - - {details.Endpoint.policy.applied.endpoint_policy_version && ( - - - - - - )} - {isPolicyOutOfDate(details.Endpoint.policy.applied, policyInfo) && ( - - - - )} - - + )} + {isPolicyOutOfDate(details.Endpoint.policy.applied, policyInfo) && } + ), }, { - title: i18n.translate('xpack.securitySolution.endpoint.details.policyStatus', { - defaultMessage: 'Policy Status', - }), + title: ( + + + + ), description: ( - + {details.agent.version}, + title: ( + + + + ), + description: {details.agent.version}, }, { - title: i18n.translate('xpack.securitySolution.endpoint.details.ipAddress', { - defaultMessage: 'IP Address', - }), + title: ( + + + + ), description: ( - - - {details.host.ip.map((ip: string, index: number) => ( - - ))} - - + + {details.host.ip.map((ip: string, index: number) => ( + + {ip} + + ))} + ), }, ]; }, [details, hostStatus, policyStatus, policyStatusClickHandler, policyInfo]); return ( - <> - + + - + ); } ); From 31e9ce7e1ff75492393345c8f60d827e86ac4712 Mon Sep 17 00:00:00 2001 From: Aleh Zasypkin Date: Wed, 17 Nov 2021 13:26:12 +0100 Subject: [PATCH 4/5] Adjust user management functional tests to work in Cloud. (#118315) --- x-pack/test/functional/apps/security/users.ts | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/x-pack/test/functional/apps/security/users.ts b/x-pack/test/functional/apps/security/users.ts index 444cf42752607..b2bef848b18e2 100644 --- a/x-pack/test/functional/apps/security/users.ts +++ b/x-pack/test/functional/apps/security/users.ts @@ -19,6 +19,10 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { const toasts = getService('toasts'); const browser = getService('browser'); + function isCloudEnvironment() { + return config.get('servers.elasticsearch.hostname') !== 'localhost'; + } + describe('users', function () { const optionalUser: UserFormValues = { username: 'OptionalUser', @@ -37,7 +41,11 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { const users = keyBy(await PageObjects.security.getElasticsearchUsers(), 'username'); log.info('actualUsers = %j', users); log.info('config = %j', config.get('servers.elasticsearch.hostname')); - if (config.get('servers.elasticsearch.hostname') === 'localhost') { + + // In Cloud default users are defined in file realm, such users aren't exposed through the Users API. + if (isCloudEnvironment()) { + expect(Object.keys(users)).to.eql(['test_user']); + } else { expect(users.elastic.roles).to.eql(['superuser']); expect(users.elastic.reserved).to.be(true); expect(users.elastic.deprecated).to.be(false); @@ -49,9 +57,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { expect(users.kibana.roles).to.eql(['kibana_system']); expect(users.kibana.reserved).to.be(true); expect(users.kibana.deprecated).to.be(true); - } else { - expect(users.anonymous.roles).to.eql(['anonymous']); - expect(users.anonymous.reserved).to.be(true); } }); From 0c4b58dfda77fe0108a71373c0c4c458f5a60693 Mon Sep 17 00:00:00 2001 From: Gloria Hornero Date: Wed, 17 Nov 2021 13:36:58 +0100 Subject: [PATCH 5/5] adds improvements and fixes to the import timeline test for the upgrade path (#118849) --- .../cypress/screens/timeline.ts | 9 ++- .../import_timeline.spec.ts | 69 ++++++++++--------- 2 files changed, 44 insertions(+), 34 deletions(-) diff --git a/x-pack/plugins/security_solution/cypress/screens/timeline.ts b/x-pack/plugins/security_solution/cypress/screens/timeline.ts index a37cd5e22ca07..845662fe051b5 100644 --- a/x-pack/plugins/security_solution/cypress/screens/timeline.ts +++ b/x-pack/plugins/security_solution/cypress/screens/timeline.ts @@ -24,7 +24,8 @@ export const SELECT_CASE = (id: string) => { return `[data-test-subj="cases-table-row-select-${id}"]`; }; -export const CELL = '[data-test-subj="statefulCell"]'; +export const CORRELATION_EVENT_TABLE_CELL = + '[data-test-subj="eql-events-table"] [data-test-subj="statefulCell"]'; export const CLOSE_TIMELINE_BTN = '[data-test-subj="close-timeline"]'; @@ -104,6 +105,9 @@ export const OPEN_TIMELINE_TEMPLATE_ICON = export const PIN_EVENT = '[data-test-subj="pin"]'; +export const PINNED_EVENT_TABLE_CELL = + '[data-test-subj="pinned-events-table"] [data-test-subj="statefulCell"]'; + export const PINNED_TAB_BUTTON = '[data-test-subj="timelineTabs-pinned"]'; export const PROCESS_KPI = '[data-test-subj="siem-timeline-process-kpi"'; @@ -120,6 +124,9 @@ export const SEARCH_OR_FILTER_CONTAINER = export const INDICATOR_MATCH_ROW_RENDER = '[data-test-subj="threat-match-row"]'; +export const QUERY_EVENT_TABLE_CELL = + '[data-test-subj="query-events-table"] [data-test-subj="statefulCell"]'; + export const QUERY_TAB_BUTTON = '[data-test-subj="timelineTabs-query"]'; export const SERVER_SIDE_EVENT_COUNT = '[data-test-subj="server-side-event-count"]'; diff --git a/x-pack/plugins/security_solution/cypress/upgrade_integration/import_timeline.spec.ts b/x-pack/plugins/security_solution/cypress/upgrade_integration/import_timeline.spec.ts index 464c42d9fc220..f3b3f14e9c260 100644 --- a/x-pack/plugins/security_solution/cypress/upgrade_integration/import_timeline.spec.ts +++ b/x-pack/plugins/security_solution/cypress/upgrade_integration/import_timeline.spec.ts @@ -6,7 +6,7 @@ */ import { - CELL, + CORRELATION_EVENT_TABLE_CELL, DATA_PROVIDERS, DATE_PICKER_END, DATE_PICKER_START, @@ -17,8 +17,10 @@ import { NOTE_DESCRIPTION, NOTE_PREVIEW, NOTES_TAB_BUTTON, + PINNED_EVENT_TABLE_CELL, PINNED_TAB_BUTTON, PROCESS_KPI, + QUERY_EVENT_TABLE_CELL, SOURCE_IP_KPI, TIMELINE_CORRELATION_TAB, TIMELINE_CORRELATION_INPUT, @@ -62,7 +64,7 @@ const timelineDetails = { }; const detectionAlert = { - timestamp: 'Oct 7, 2021 @ 11:14:10.888', + timestamp: 'Nov 17, 2021 @ 09:36:25.499', message: '—', eventCategory: 'file', eventAction: 'initial_scan', @@ -73,7 +75,7 @@ const detectionAlert = { }; const event = { - timestamp: 'Oct 6, 2021 @ 17:09:29.438', + timestamp: 'Nov 4, 2021 @ 11:09:29.438', message: '—', eventCategory: 'file', eventAction: 'initial_scan', @@ -98,7 +100,7 @@ describe('Import timeline after upgrade', () => { cy.readFile(`cypress/fixtures/${timeline}`).then((file) => { const timelineJson = JSON.parse(file); const regex = new RegExp( - `\\S${timelineJson.globalNotes[0].createdBy}added a note\\d* \\w* ago${timelineJson.globalNotes[0].createdBy} added a note${timelineJson.globalNotes[0].note}` + `\\S${timelineJson.globalNotes[0].createdBy}added a note\\S*\\s?(\\S*)?\\s?(\\S*)?${timelineJson.globalNotes[0].createdBy} added a note${timelineJson.globalNotes[0].note}` ); cy.get(TIMELINE_NAME).should('have.text', timelineJson.title); @@ -147,30 +149,31 @@ describe('Import timeline after upgrade', () => { cy.get(NOTES_TAB_BUTTON).should('have.text', timelineDetails.notesTab); cy.get(PINNED_TAB_BUTTON).should('have.text', timelineDetails.pinnedTab); - cy.get(CELL).eq(0).should('contain', detectionAlert.timestamp); - cy.get(CELL).eq(1).should('contain', detectionAlert.message); - cy.get(CELL).eq(2).should('contain', detectionAlert.eventCategory); - cy.get(CELL).eq(3).should('contain', detectionAlert.eventAction); - cy.get(CELL).eq(4).should('contain', detectionAlert.hostName); - cy.get(CELL).eq(5).should('contain', detectionAlert.sourceIp); - cy.get(CELL).eq(6).should('contain', detectionAlert.destinationIp); - cy.get(CELL).eq(7).should('contain', detectionAlert.userName); - - cy.get(CELL).eq(8).should('contain', event.timestamp); - cy.get(CELL).eq(9).should('contain', event.message); - cy.get(CELL).eq(10).should('contain', event.eventCategory); - cy.get(CELL).eq(11).should('contain', event.eventAction); - cy.get(CELL).eq(12).should('contain', event.hostName); - cy.get(CELL).eq(13).should('contain', event.sourceIp); - cy.get(CELL).eq(14).should('contain', event.destinationIp); - cy.get(CELL).eq(15).should('contain', event.userName); + cy.get(QUERY_EVENT_TABLE_CELL).eq(0).should('contain', detectionAlert.timestamp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(1).should('contain', detectionAlert.message); + cy.get(QUERY_EVENT_TABLE_CELL).eq(2).should('contain', detectionAlert.eventCategory); + cy.get(QUERY_EVENT_TABLE_CELL).eq(3).should('contain', detectionAlert.eventAction); + cy.get(QUERY_EVENT_TABLE_CELL).eq(4).should('contain', detectionAlert.hostName); + cy.get(QUERY_EVENT_TABLE_CELL).eq(5).should('contain', detectionAlert.sourceIp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(6).should('contain', detectionAlert.destinationIp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(7).should('contain', detectionAlert.userName); + + cy.get(QUERY_EVENT_TABLE_CELL).eq(8).should('contain', event.timestamp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(9).should('contain', event.message); + cy.get(QUERY_EVENT_TABLE_CELL).eq(10).should('contain', event.eventCategory); + cy.get(QUERY_EVENT_TABLE_CELL).eq(11).should('contain', event.eventAction); + cy.get(QUERY_EVENT_TABLE_CELL).eq(12).should('contain', event.hostName); + cy.get(QUERY_EVENT_TABLE_CELL).eq(13).should('contain', event.sourceIp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(14).should('contain', event.destinationIp); + cy.get(QUERY_EVENT_TABLE_CELL).eq(15).should('contain', event.userName); }); }); - it('Displays the correct timeline details inside the query tab', () => { + it('Displays the correct timeline details inside the correlation tab', () => { goToCorrelationTab(); cy.get(TIMELINE_CORRELATION_INPUT).should('be.empty'); + cy.get(CORRELATION_EVENT_TABLE_CELL).should('not.exist'); }); it('Displays the correct timeline details inside the notes tab', () => { @@ -179,27 +182,27 @@ describe('Import timeline after upgrade', () => { cy.readFile(`cypress/fixtures/${timeline}`).then((file) => { const timelineJson = JSON.parse(file); const descriptionRegex = new RegExp( - `\\S${username}added description\\d* \\w* ago${timelineJson.description}` + `\\S${username}added description\\S*\\s?(\\S*)?\\s?(\\S*)?${timelineJson.description}` ); const noteRegex = new RegExp( - `\\S${timelineJson.globalNotes[0].createdBy}added a note\\d* \\w* ago${timelineJson.globalNotes[0].createdBy} added a note${timelineJson.globalNotes[0].note}` + `\\S${timelineJson.globalNotes[0].createdBy}added a note\\S*\\s?(\\S*)?\\s?(\\S*)?${timelineJson.globalNotes[0].createdBy} added a note${timelineJson.globalNotes[0].note}` ); cy.get(NOTE_DESCRIPTION).invoke('text').should('match', descriptionRegex); - cy.get(NOTE_PREVIEW).invoke('text').should('match', noteRegex); + cy.get(NOTE_PREVIEW).last().invoke('text').should('match', noteRegex); }); }); it('Displays the correct timeline details inside the pinned tab', () => { goToPinnedTab(); - cy.get(CELL).eq(0).should('contain', detectionAlert.timestamp); - cy.get(CELL).eq(1).should('contain', detectionAlert.message); - cy.get(CELL).eq(2).should('contain', detectionAlert.eventCategory); - cy.get(CELL).eq(3).should('contain', detectionAlert.eventAction); - cy.get(CELL).eq(4).should('contain', detectionAlert.hostName); - cy.get(CELL).eq(5).should('contain', detectionAlert.sourceIp); - cy.get(CELL).eq(6).should('contain', detectionAlert.destinationIp); - cy.get(CELL).eq(7).should('contain', detectionAlert.userName); + cy.get(PINNED_EVENT_TABLE_CELL).eq(0).should('contain', detectionAlert.timestamp); + cy.get(PINNED_EVENT_TABLE_CELL).eq(1).should('contain', detectionAlert.message); + cy.get(PINNED_EVENT_TABLE_CELL).eq(2).should('contain', detectionAlert.eventCategory); + cy.get(PINNED_EVENT_TABLE_CELL).eq(3).should('contain', detectionAlert.eventAction); + cy.get(PINNED_EVENT_TABLE_CELL).eq(4).should('contain', detectionAlert.hostName); + cy.get(PINNED_EVENT_TABLE_CELL).eq(5).should('contain', detectionAlert.sourceIp); + cy.get(PINNED_EVENT_TABLE_CELL).eq(6).should('contain', detectionAlert.destinationIp); + cy.get(PINNED_EVENT_TABLE_CELL).eq(7).should('contain', detectionAlert.userName); }); });