From 8cf8ed40d3a2704bf3158f965099b424f6c50232 Mon Sep 17 00:00:00 2001 From: Ievgen Sorokopud Date: Thu, 20 Jul 2023 11:21:45 +0200 Subject: [PATCH] [Security Solution] Test rule_details_ui/pages/rule_details/index.test.tsx logs a warning about wrong props passed to EuiSwitch (#162229) ## Summary Related ticket: https://github.com/elastic/kibana/issues/147065 This PR fixes the warning within the `rule_details_ui/pages/rule_details/index.test.tsx` test which happens because instead of using required `EuiSwitch`'s `label` field we pass `undefined`. Since, we do not intend to show the label we make it explicitly with `showLabel={false}` and set `label` to an empty string. For more details see [the overview of the EuiSwitch](https://elastic.github.io/eui/#/forms/selection-controls) component. --- .../public/detections/components/rules/rule_switch/index.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx index d9fea527649473..7e4881800f738d 100644 --- a/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx @@ -88,7 +88,8 @@ export const RuleSwitchComponent = ({ ) : (