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

sancho-v1.0.4-alpha #1274

Merged
merged 65 commits into from
Jun 13, 2024
Merged
Changes from 1 commit
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
8b157a8
fix: proposal sorting logic in test
NabinKawan Jun 6, 2024
430ff15
fix: proposal filtering validation in test
NabinKawan Jun 6, 2024
9871eaa
chore: Address interference from wallet connected toast notification …
NabinKawan Jun 6, 2024
9e5ebcb
chore: Remove retries for 2E, and 2S
NabinKawan Jun 6, 2024
5184431
fix: Resolve balance issue in test case 2W
NabinKawan Jun 6, 2024
aa1ec04
chore: Update temporary wallets count
NabinKawan Jun 6, 2024
cb173e3
fix: Resolve wallet popup timeout issue in voting
NabinKawan Jun 6, 2024
c1e3118
chore: Replace hardcoded dRep registration amount with protocol params
NabinKawan Jun 6, 2024
903cc51
chore: Refactor test title numbering
kneerose Jun 5, 2024
1eed031
chore: Add proposal setup to generate temporary proposal wallets
kneerose Jun 6, 2024
b12e03d
fix: Proposal submission wallet issue
kneerose Jun 6, 2024
3519400
fix: Theme provider issue in storybook
NabinKawan Jun 10, 2024
fc350fe
fix: ActionsBar interactions test
NabinKawan Jun 10, 2024
7cc82db
fix: test interaction loading button
NabinKawan Jun 10, 2024
a5da0ac
Add interaction tests for card
NabinKawan Jun 10, 2024
6033b44
Add interaction tests for checkbox
NabinKawan Jun 10, 2024
91fde96
chore: Update DashboardTopNav interaction test
NabinKawan Jun 10, 2024
67d95c9
chore: Update DelegationActionRadio interaction test
NabinKawan Jun 10, 2024
fa48c61
chore: Update footer interaction test
NabinKawan Jun 10, 2024
d8feb98
chore: Add interaction tests for (data-missing, format incorrect, not…
NabinKawan Jun 10, 2024
889e817
test: Invalid GovernanceAction details
NabinKawan Jun 11, 2024
8b22deb
chore: refactor tests for Input story and add interaction for 'helpfu…
NabinKawan Jun 11, 2024
31c1d48
test: story LinkWithIcon
NabinKawan Jun 11, 2024
365d7b5
chore: test Slider component overflow
NabinKawan Jun 11, 2024
9dd228b
test: story StatusPill
NabinKawan Jun 11, 2024
3508c5c
test: story Step
NabinKawan Jun 11, 2024
a828db2
test: story TextArea
NabinKawan Jun 11, 2024
b07a830
chore: Remove home-link in TopNav story
NabinKawan Jun 11, 2024
be10f7e
test: story loading modal
NabinKawan Jun 11, 2024
917e503
test: story Voting Power Model
NabinKawan Jun 11, 2024
789ac3b
test: story dashboard card
NabinKawan Jun 11, 2024
5ff75a3
chore: Increase interaction test timeout to 30 sec
NabinKawan Jun 11, 2024
39af694
fix: story Footer interaction (feedback-footer-button)
NabinKawan Jun 11, 2024
b1badcc
chore: Remove helps-link test from Drawer story
NabinKawan Jun 11, 2024
1923281
chore: Add auth token config for pdf-ui
NabinKawan Jun 11, 2024
91c2a65
chore: Update test-storybook script in workflow
NabinKawan Jun 11, 2024
362b598
reward address CSL validation
Sworzen1 Jun 11, 2024
b619457
add tests
Sworzen1 Jun 11, 2024
d359595
Merge pull request #1241 from IntersectMBO/fix/storybook-workflow-aut…
NabinKawan Jun 12, 2024
4c9f2b9
Merge pull request #1217 from IntersectMBO/fix/proposal-submission-wa…
NabinKawan Jun 12, 2024
41e307d
Merge pull request #1179 from IntersectMBO/fix/tests-proposal-filter
NabinKawan Jun 12, 2024
3fee2c4
Merge pull request #1182 from IntersectMBO/fix/flaky-tests
NabinKawan Jun 12, 2024
42a2be9
Merge pull request #1240 from IntersectMBO/feat/storybook-tests
NabinKawan Jun 12, 2024
0e350ea
chore: Update protocol params type to 'ProtocolParams'
NabinKawan Jun 12, 2024
53ed99e
Merge pull request #1251 from IntersectMBO/fix/1231-ga-treasury-unabl…
Sworzen1 Jun 12, 2024
5c5bb60
Merge pull request #1184 from IntersectMBO/enhancement/transaction-am…
NabinKawan Jun 12, 2024
e129035
change about to abstract
Sworzen1 Jun 12, 2024
d7b34d1
#1253 add ellipsize text for drep name
Sworzen1 Jun 12, 2024
6a53925
fix: fix governance action provider metadata creation
MSzalowski Jun 12, 2024
2cd8eba
Update docs/GOVERNANCE_ACTION_SUBMISSION.md
MSzalowski Jun 12, 2024
ac93f5f
fix: replace link with uri in all metadatas
MSzalowski Jun 12, 2024
047fb22
Merge pull request #1261 from IntersectMBO/fix/fix-references-in-json…
MSzalowski Jun 12, 2024
b66ed5d
#1257 hide delegation for delegation on myself
Sworzen1 Jun 12, 2024
2d9680b
#1257 improvememnt for abstain and no
Sworzen1 Jun 12, 2024
51b956b
#1253 improvement
Sworzen1 Jun 12, 2024
002734a
feat(#1246): update link to docs
MSzalowski Jun 12, 2024
42a9010
Merge pull request #1263 from IntersectMBO/feat/1246-update-link-to-docs
MSzalowski Jun 12, 2024
bb489f2
Merge pull request #1262 from IntersectMBO/fix/1257-dashboard-shows-d…
Sworzen1 Jun 12, 2024
983b1e0
Merge pull request #1258 from IntersectMBO/fix/1243-bug-incorrect-lab…
Sworzen1 Jun 12, 2024
09c0ade
chore: get rid of unused packages
MSzalowski Jun 12, 2024
636cf98
Merge pull request #1259 from IntersectMBO/fix/1253-dashboard-drep-ex…
Sworzen1 Jun 12, 2024
aacd543
Merge pull request #1264 from IntersectMBO/chore/get-rid-of-unused-pa…
MSzalowski Jun 12, 2024
1f569ca
fix(#1252): fix link to the GA details once in in progress
MSzalowski Jun 12, 2024
faf4605
Merge pull request #1265 from IntersectMBO/fix/1252-view-details-take…
MSzalowski Jun 12, 2024
7bdcf43
Merge pull request #1266 from IntersectMBO/develop
MSzalowski Jun 12, 2024
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
28 changes: 26 additions & 2 deletions govtool/frontend/src/stories/LinkWithIcon.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
import { Meta, StoryObj } from "@storybook/react";
import { LinkWithIcon } from "@molecules";
import { ICONS } from "@consts";
import { LinkWithIcon } from "@molecules";
import { expect, jest } from "@storybook/jest";
import { Meta, StoryObj } from "@storybook/react";
import { userEvent, within } from "@storybook/testing-library";

const meta: Meta<typeof LinkWithIcon> = {
title: "Example/LinkWithIcon",
component: LinkWithIcon,
args: {
onClick: jest.fn(),
},

parameters: {
layout: "centered",
},
@@ -16,11 +22,29 @@ export const Default: StoryObj<typeof LinkWithIcon> = {
args: {
label: "Default Link",
},
play: async ({ canvasElement, args }) => {
const canvas = within(canvasElement);

await expect(canvas.getByTestId("ArrowBackIosIcon")).toBeVisible();
await userEvent.click(
canvas.getByTestId(`${args.label.replace(/\s/g, "-")}-link`),
);
await expect(args.onClick).toHaveBeenCalled();
},
};

export const WithCustomIcon: StoryObj<typeof LinkWithIcon> = {
args: {
label: "Custom Icon Link",
icon: <img alt="custom icon" src={ICONS.link} />,
},
play: async ({ canvasElement, args }) => {
const canvas = within(canvasElement);

await expect(canvas.getByRole("img")).toHaveAttribute("alt", "custom icon");
await userEvent.click(
canvas.getByTestId(`${args.label.replace(/\s/g, "-")}-link`),
);
await expect(args.onClick).toHaveBeenCalled();
},
};