Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add some locators #468

Merged
merged 1 commit into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/app/communities/CommunityItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const CommunityItem = ({
description,
numberOfMembers,
}: CommunityItemProps) => (
<div className="rounded-[8px] bg-input-bg p-[16px] w-[358px]">
<div className="rounded-[8px] bg-input-bg p-[16px] w-[358px]" data-testid={`${title}Card`}>
<Link
href={nftAddress ? `/communities/nft/${nftAddress}` : '/communities'}
className="flex flex-col h-full"
Expand Down
4 changes: 3 additions & 1 deletion src/app/proposals/LatestProposalsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,9 @@ const LatestProposalsTable = ({ latestProposals }: LatestProposalsTableProps) =>
/>
</SharedProposalsTableContextProvider>
) : (
<Typography tagVariant="p">No proposals found &#x1F622;</Typography>
<Typography tagVariant="p" data-testid="NoProposals">
No proposals found &#x1F622;
</Typography>
)}
</div>
)
Expand Down
2 changes: 1 addition & 1 deletion src/app/proposals/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ const VotingPowerPopover = () => (
<Popover content={<PopoverContent />}>
<button className="flex flex-row">
<Paragraph className="text[16px] font-[700]">My Voting Power</Paragraph>
<FaRegQuestionCircle className="ml-1 self-center" />
<FaRegQuestionCircle className="ml-1 self-center" data-testid="QuestionIcon" />
</button>
</Popover>
)
2 changes: 1 addition & 1 deletion src/app/user/Communities/CommunityCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Image from 'next/image'
import Link from 'next/link'

export const CommunityCard: FC<CommunityCardProps> = ({ img, title, description, members, link }) => (
<div className="rounded bg-input-bg w-[300px]">
<div className="rounded bg-input-bg w-[300px]" data-testId={`${title}Card`}>
<Link href={link}>
{/* image */}
<Image
Expand Down
4 changes: 2 additions & 2 deletions src/components/Input/Input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ export const Input: FC<Props> = ({
search: (
<div className="relative">
<div className="absolute translate-y-4 translate-x-4">
{loading ? <FaSpinner className="animate-spin" /> : <BsSearch />}
{loading ? <FaSpinner className="animate-spin" /> : <BsSearch data-testid="SearchIcon" />}
</div>
<input
className={classes}
Expand All @@ -118,7 +118,7 @@ export const Input: FC<Props> = ({
{/* Small clear button at the right of the search field */}
{onClear && (
<button onClick={onClear} className="absolute right-4 bottom-1/2 translate-y-1/2 cursor-pointer">
<BsXCircle />
<BsXCircle data-testid="ClearIcon" />
</button>
)}
</div>
Expand Down
Loading