Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mertsincan committed Nov 27, 2023
1 parent b41bf5f commit 1399e47
Show file tree
Hide file tree
Showing 5 changed files with 68 additions and 5 deletions.
8 changes: 8 additions & 0 deletions components/lib/blockui/__snapshots__/BlockUI.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ exports[`BlockUI block and unblock fullscreen events: blocked-event-fullscreen 1
>
<div>
<div
aria-busy="false"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand All @@ -27,6 +28,7 @@ exports[`BlockUI block and unblock fullscreen events: unblocked-event-fullscreen
>
<div>
<div
aria-busy="false"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand All @@ -43,6 +45,7 @@ exports[`BlockUI block and unblock fullscreen events: unblocked-event-fullscreen
exports[`BlockUI block and unblock panel events: blocked-event 1`] = `
<div>
<div
aria-busy="false"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand Down Expand Up @@ -81,6 +84,7 @@ exports[`BlockUI block and unblock panel events: blocked-event 1`] = `
exports[`BlockUI block and unblock panel events: unblocked-event 1`] = `
<div>
<div
aria-busy="false"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand Down Expand Up @@ -123,6 +127,7 @@ exports[`BlockUI block fullscreen 1`] = `
>
<div>
<div
aria-busy="true"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand All @@ -143,6 +148,7 @@ exports[`BlockUI block panel 1`] = `
>
<div>
<div
aria-busy="true"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand Down Expand Up @@ -186,6 +192,7 @@ exports[`BlockUI container style and className 1`] = `
>
<div>
<div
aria-busy="true"
class="p-blockui-container container-jest"
data-pc-name="blockui"
data-pc-section="root"
Expand Down Expand Up @@ -230,6 +237,7 @@ exports[`BlockUI unblock panel 1`] = `
>
<div>
<div
aria-busy="false"
class="p-blockui-container"
data-pc-name="blockui"
data-pc-section="root"
Expand Down
46 changes: 45 additions & 1 deletion components/lib/chip/__snapshots__/Chip.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ exports[`Chip image and alt 1`] = `
exports[`Chip label 1`] = `
<div>
<div
aria-label="jest"
class="p-chip p-component"
data-pc-name="chip"
data-pc-section="root"
Expand All @@ -74,7 +75,50 @@ exports[`Chip label 1`] = `
</div>
`;

exports[`Chip when removable is true it returns with remove icon: after remove 1`] = `<div />`;
exports[`Chip when removable is true it returns with remove icon: after remove 1`] = `
<div>
<div
class="p-chip p-component"
data-pc-name="chip"
data-pc-section="root"
>
<svg
aria-hidden="true"
class="p-icon p-chip-remove-icon"
data-pc-section="removeicon"
fill="none"
height="14"
role="button"
tabindex="0"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<g
clip-path="url(#pr_icon_clip_1)"
>
<path
clip-rule="evenodd"
d="M7 14C5.61553 14 4.26215 13.5895 3.11101 12.8203C1.95987 12.0511 1.06266 10.9579 0.532846 9.67879C0.00303296 8.3997 -0.13559 6.99224 0.134506 5.63437C0.404603 4.2765 1.07129 3.02922 2.05026 2.05026C3.02922 1.07129 4.2765 0.404603 5.63437 0.134506C6.99224 -0.13559 8.3997 0.00303296 9.67879 0.532846C10.9579 1.06266 12.0511 1.95987 12.8203 3.11101C13.5895 4.26215 14 5.61553 14 7C14 8.85652 13.2625 10.637 11.9497 11.9497C10.637 13.2625 8.85652 14 7 14ZM7 1.16667C5.84628 1.16667 4.71846 1.50879 3.75918 2.14976C2.79989 2.79074 2.05222 3.70178 1.61071 4.76768C1.16919 5.83358 1.05367 7.00647 1.27876 8.13803C1.50384 9.26958 2.05941 10.309 2.87521 11.1248C3.69102 11.9406 4.73042 12.4962 5.86198 12.7212C6.99353 12.9463 8.16642 12.8308 9.23232 12.3893C10.2982 11.9478 11.2093 11.2001 11.8502 10.2408C12.4912 9.28154 12.8333 8.15373 12.8333 7C12.8333 5.45291 12.2188 3.96918 11.1248 2.87521C10.0308 1.78125 8.5471 1.16667 7 1.16667ZM4.66662 9.91668C4.58998 9.91704 4.51404 9.90209 4.44325 9.87271C4.37246 9.84333 4.30826 9.8001 4.2544 9.74557C4.14516 9.6362 4.0838 9.48793 4.0838 9.33335C4.0838 9.17876 4.14516 9.0305 4.2544 8.92113L6.17553 7L4.25443 5.07891C4.15139 4.96832 4.09529 4.82207 4.09796 4.67094C4.10063 4.51982 4.16185 4.37563 4.26872 4.26876C4.3756 4.16188 4.51979 4.10066 4.67091 4.09799C4.82204 4.09532 4.96829 4.15142 5.07887 4.25446L6.99997 6.17556L8.92106 4.25446C9.03164 4.15142 9.1779 4.09532 9.32903 4.09799C9.48015 4.10066 9.62434 4.16188 9.73121 4.26876C9.83809 4.37563 9.89931 4.51982 9.90198 4.67094C9.90464 4.82207 9.84855 4.96832 9.74551 5.07891L7.82441 7L9.74554 8.92113C9.85478 9.0305 9.91614 9.17876 9.91614 9.33335C9.91614 9.48793 9.85478 9.6362 9.74554 9.74557C9.69168 9.8001 9.62748 9.84333 9.55669 9.87271C9.4859 9.90209 9.40996 9.91704 9.33332 9.91668C9.25668 9.91704 9.18073 9.90209 9.10995 9.87271C9.03916 9.84333 8.97495 9.8001 8.9211 9.74557L6.99997 7.82444L5.07884 9.74557C5.02499 9.8001 4.96078 9.84333 4.88999 9.87271C4.81921 9.90209 4.74326 9.91704 4.66662 9.91668Z"
fill="currentColor"
fill-rule="evenodd"
/>
</g>
<defs>
<clippath
id="pr_icon_clip_1"
>
<rect
fill="white"
height="14"
width="14"
/>
</clippath>
</defs>
</svg>
</div>
</div>
`;

exports[`Chip when removable is true it returns with remove icon: before remove 1`] = `
<div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ exports[`ProgressBar mode determinate 1`] = `
exports[`ProgressBar mode indeterminate 1`] = `
<div>
<div
aria-valuemax="100"
aria-valuemin="0"
class="p-progressbar p-component p-progressbar-indeterminate"
data-pc-name="progressbar"
data-pc-section="root"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ exports[`ProgressSpinner animationDuration 1`] = `
class="p-progress-spinner"
data-pc-name="progressspinner"
data-pc-section="root"
role="alert"
role="progressbar"
>
<svg
class="p-progress-spinner-svg"
Expand Down Expand Up @@ -37,7 +37,7 @@ exports[`ProgressSpinner default 1`] = `
class="p-progress-spinner"
data-pc-name="progressspinner"
data-pc-section="root"
role="alert"
role="progressbar"
>
<svg
class="p-progress-spinner-svg"
Expand Down Expand Up @@ -67,7 +67,7 @@ exports[`ProgressSpinner fill 1`] = `
class="p-progress-spinner"
data-pc-name="progressspinner"
data-pc-section="root"
role="alert"
role="progressbar"
>
<svg
class="p-progress-spinner-svg"
Expand Down Expand Up @@ -97,7 +97,7 @@ exports[`ProgressSpinner strokeWidth 1`] = `
class="p-progress-spinner"
data-pc-name="progressspinner"
data-pc-section="root"
role="alert"
role="progressbar"
>
<svg
class="p-progress-spinner-svg"
Expand Down
9 changes: 9 additions & 0 deletions components/lib/skeleton/__snapshots__/Skeleton.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
exports[`Skeleton animation none 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component p-skeleton-none"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -14,6 +15,7 @@ exports[`Skeleton animation none 1`] = `
exports[`Skeleton animation wave 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -25,6 +27,7 @@ exports[`Skeleton animation wave 1`] = `
exports[`Skeleton border radius 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -36,6 +39,7 @@ exports[`Skeleton border radius 1`] = `
exports[`Skeleton border radius 2`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -47,6 +51,7 @@ exports[`Skeleton border radius 2`] = `
exports[`Skeleton default 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -58,6 +63,7 @@ exports[`Skeleton default 1`] = `
exports[`Skeleton shape circle 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component p-skeleton-circle"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -69,6 +75,7 @@ exports[`Skeleton shape circle 1`] = `
exports[`Skeleton shape rectangle 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -80,6 +87,7 @@ exports[`Skeleton shape rectangle 1`] = `
exports[`Skeleton size in pixels 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand All @@ -91,6 +99,7 @@ exports[`Skeleton size in pixels 1`] = `
exports[`Skeleton size width and height 1`] = `
<div>
<div
aria-hidden="true"
class="p-skeleton p-component"
data-pc-name="skeleton"
data-pc-section="root"
Expand Down

0 comments on commit 1399e47

Please sign in to comment.