diff --git a/x-pack/test/security_solution_cypress/cypress/screens/rule_details.ts b/x-pack/test/security_solution_cypress/cypress/screens/rule_details.ts index e5d6711b7d16e..f6436249a53c8 100644 --- a/x-pack/test/security_solution_cypress/cypress/screens/rule_details.ts +++ b/x-pack/test/security_solution_cypress/cypress/screens/rule_details.ts @@ -138,7 +138,8 @@ export const TIMELINE_FIELD = (field: string) => { return `[data-test-subj="formatted-field-${field}"]`; }; -export const removeExternalLinkText = (str: string) => str.replace(/\(external[^)]*\)/g, ''); +export const removeExternalLinkText = (str: string) => + str.replace(/\([^)]*(opens in a new tab or window)[^)]*\)/g, ''); export const DEFINE_RULE_PANEL_PROGRESS = '[data-test-subj="defineRule"] [data-test-subj="stepPanelProgress"]';