From cebaac8477864174d68626d3f8aec1d28c5d2cf5 Mon Sep 17 00:00:00 2001 From: Sergio Betanzos Date: Thu, 19 May 2022 14:01:05 +0200 Subject: [PATCH] M #~: Add data-cy selector to testing (#2064) --- src/fireedge/src/client/components/Forms/FormWithSchema.js | 1 + src/fireedge/src/client/components/Forms/Legend.js | 5 +++-- .../Steps/ExtraConfiguration/context/contextVarsSection.js | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/fireedge/src/client/components/Forms/FormWithSchema.js b/src/fireedge/src/client/components/Forms/FormWithSchema.js index c6285ed2a6..11d67f4404 100644 --- a/src/fireedge/src/client/components/Forms/FormWithSchema.js +++ b/src/fireedge/src/client/components/Forms/FormWithSchema.js @@ -114,6 +114,7 @@ const FormWithSchema = ({ {legend && ( ( ) const Legend = memo( - ({ title, tooltip, disableGutters }) => ( - + ({ 'data-cy': dataCy, title, tooltip, disableGutters }) => ( + {!!tooltip && } @@ -49,6 +49,7 @@ const Legend = memo( ) Legend.propTypes = { + 'data-cy': PropTypes.string, title: PropTypes.any, tooltip: PropTypes.string, disableGutters: PropTypes.bool, diff --git a/src/fireedge/src/client/components/Forms/VmTemplate/CreateForm/Steps/ExtraConfiguration/context/contextVarsSection.js b/src/fireedge/src/client/components/Forms/VmTemplate/CreateForm/Steps/ExtraConfiguration/context/contextVarsSection.js index 5573b4a02d..86dbd038bd 100644 --- a/src/fireedge/src/client/components/Forms/VmTemplate/CreateForm/Steps/ExtraConfiguration/context/contextVarsSection.js +++ b/src/fireedge/src/client/components/Forms/VmTemplate/CreateForm/Steps/ExtraConfiguration/context/contextVarsSection.js @@ -81,6 +81,7 @@ const ContextVarsSection = ({ hypervisor }) => {