element-web/test/components/views/rooms/__snapshots__/MemberTile-test.tsx.snap
Florian Duros d40092c9da
Element-R: Use MatrixClient.CryptoApi.getUserVerificationStatus instead of MatrixClient.checkUserTrust in MemberTile.tsx (#11701)
* Use `MatrixClient.CryptoApi.getUserVerificationStatus` instead of `MatrixClient.checkUserTrust` in `MemberTile.tsx`

* Add tests to `MemberTile.tsx`

* Use `mocked` instead of `spyOn`
2023-10-04 13:01:39 +00:00

168 lines
3.9 KiB
Text

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`MemberTile should display an verified E2EIcon when the e2E status = Verified 1`] = `
<div>
<div>
<div
class="mx_AccessibleButton mx_EntityTile mx_EntityTile_offline_neveractive"
role="button"
tabindex="0"
title="@userId:matrix.org (power 0)"
>
<div
class="mx_EntityTile_avatar"
>
<span
aria-hidden="true"
class="_avatar_ylj7w_17 mx_BaseAvatar _avatar-imageless_ylj7w_56"
data-color="2"
data-testid="avatar-img"
data-type="round"
role="presentation"
style="--cpd-avatar-size: 36px;"
title="@userId:matrix.org"
>
u
</span>
<div
aria-label="You have verified this user. This user has verified all of their sessions."
class="mx_E2EIcon mx_E2EIcon_bordered mx_E2EIcon_verified"
/>
</div>
<div
class="mx_EntityTile_details"
>
<div
class="mx_EntityTile_name"
>
<div
class="mx_DisambiguatedProfile"
>
<span
class=""
dir="auto"
>
@userId:matrix.org
</span>
</div>
</div>
<div
class="mx_PresenceLabel"
>
Offline
</div>
</div>
</div>
</div>
</div>
`;
exports[`MemberTile should display an warning E2EIcon when the e2E status = Warning 1`] = `
<div>
<div>
<div
class="mx_AccessibleButton mx_EntityTile mx_EntityTile_offline_neveractive"
role="button"
tabindex="0"
title="@userId:matrix.org (power 0)"
>
<div
class="mx_EntityTile_avatar"
>
<span
aria-hidden="true"
class="_avatar_ylj7w_17 mx_BaseAvatar _avatar-imageless_ylj7w_56"
data-color="2"
data-testid="avatar-img"
data-type="round"
role="presentation"
style="--cpd-avatar-size: 36px;"
title="@userId:matrix.org"
>
u
</span>
<div
aria-label="This user has not verified all of their sessions."
class="mx_E2EIcon mx_E2EIcon_bordered mx_E2EIcon_warning"
/>
</div>
<div
class="mx_EntityTile_details"
>
<div
class="mx_EntityTile_name"
>
<div
class="mx_DisambiguatedProfile"
>
<span
class=""
dir="auto"
>
@userId:matrix.org
</span>
</div>
</div>
<div
class="mx_PresenceLabel"
>
Offline
</div>
</div>
</div>
</div>
</div>
`;
exports[`MemberTile should not display an E2EIcon when the e2E status = normal 1`] = `
<div>
<div>
<div
class="mx_AccessibleButton mx_EntityTile mx_EntityTile_offline_neveractive"
role="button"
tabindex="0"
title="@userId:matrix.org (power 0)"
>
<div
class="mx_EntityTile_avatar"
>
<span
aria-hidden="true"
class="_avatar_ylj7w_17 mx_BaseAvatar _avatar-imageless_ylj7w_56"
data-color="2"
data-testid="avatar-img"
data-type="round"
role="presentation"
style="--cpd-avatar-size: 36px;"
title="@userId:matrix.org"
>
u
</span>
</div>
<div
class="mx_EntityTile_details"
>
<div
class="mx_EntityTile_name"
>
<div
class="mx_DisambiguatedProfile"
>
<span
class=""
dir="auto"
>
@userId:matrix.org
</span>
</div>
</div>
<div
class="mx_PresenceLabel"
>
Offline
</div>
</div>
</div>
</div>
</div>
`;