Skip to content

Commit 178fb88

Browse files
committed
test(ui): identify Alice's account row by her username
1 parent 7704762 commit 178fb88

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎packages/ui/src/mosaic/user-button/__tests__/user-button.integration.test.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,8 @@ async function open() {
194194
return act;
195195
}
196196

197-
const accountMenu = () => screen.getByRole('button', { name: 'Actions for alice@example.com' });
197+
// Alice has a username, so that is what identifies her row; Bob has none and falls back to email.
198+
const accountMenu = () => screen.getByRole('button', { name: 'Actions for alice' });
198199

199200
/** Opens the `⋯` on the active account's row and clicks one of its actions. */
200201
async function accountAction(act: ReturnType<typeof userEvent.setup>, label: string) {

0 commit comments

Comments
 (0)