chore: add data-test attributes
parent
4afab8f977
commit
5f85263d00
|
@ -38,6 +38,7 @@ class RoleEditingRow extends Component {
|
||||||
autoFocus={true}
|
autoFocus={true}
|
||||||
spellCheck={false}
|
spellCheck={false}
|
||||||
autoComplete="false"
|
autoComplete="false"
|
||||||
|
data-test="role-name--input"
|
||||||
/>
|
/>
|
||||||
</td>
|
</td>
|
||||||
)
|
)
|
||||||
|
|
|
@ -67,7 +67,7 @@ const RoleRow = ({
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<tr>
|
<tr data-test={`role-${roleName}--row`}>
|
||||||
<td style={{width: `${ROLES_TABLE.colName}px`}}>{roleName}</td>
|
<td style={{width: `${ROLES_TABLE.colName}px`}}>{roleName}</td>
|
||||||
<td>
|
<td>
|
||||||
{allPermissions && allPermissions.length ? (
|
{allPermissions && allPermissions.length ? (
|
||||||
|
|
|
@ -74,6 +74,7 @@ const UserRow = ({
|
||||||
<td
|
<td
|
||||||
className="admin-table--left-offset"
|
className="admin-table--left-offset"
|
||||||
title={!allRoles.length ? 'No roles are defined' : ''}
|
title={!allRoles.length ? 'No roles are defined' : ''}
|
||||||
|
data-test="roles-granted"
|
||||||
>
|
>
|
||||||
{user.roles.map((role, i) => (
|
{user.roles.map((role, i) => (
|
||||||
<span key={i} className="role-value granted">
|
<span key={i} className="role-value granted">
|
||||||
|
|
|
@ -383,6 +383,7 @@ const UserPage = ({
|
||||||
: ''
|
: ''
|
||||||
}`}
|
}`}
|
||||||
onClick={onRoleChange}
|
onClick={onRoleChange}
|
||||||
|
data-test={`role-${roleName}--button`}
|
||||||
>
|
>
|
||||||
{roleName}
|
{roleName}
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue