1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-22 18:50:08 +03:00

F #5422: Add data-cy for settings tests (#2225)

(cherry picked from commit ad58c84d07e0b749ac116cb68609ad5b6456064e)
This commit is contained in:
Frederick Borges 2022-07-07 17:37:38 +02:00 committed by Tino Vazquez
parent 7b9b4711b0
commit ff2703084b

View File

@ -93,6 +93,7 @@ const FieldComponent = memo(
variant="outlined"
onKeyDown={handleKeyDown}
helperText={<Translate word={T.PressEscapeToCancel} />}
inputProps={{ 'data-cy': `settings-ui-text-${name}` }}
{...register(name, { onBlur: handleBlur, shouldUnregister: true })}
/>
)
@ -206,6 +207,7 @@ const Settings = () => {
component="fieldset"
key={'settings-authentication-field-' + field.name}
sx={{ minInlineSize: 'auto' }}
data-cy={`settings-ui-${field.name}`}
>
<Legend title={field.label} />
{isEnabled[field.name] ? (