feat(cases): adiciona o case Julia Beauty com vídeo de rolagem
This commit is contained in:
1 parent
594daecd2b
commit
bcdf0099c5
26 files changed
+159
-42
No files matched your search
@@ -84,6 +84,7 @@ const WEIGHTS = [
|
||||
"nutriscan",
|
||||
"sc-plus",
|
||||
"as-servicos",
|
||||
"julia-beauty",
|
||||
].map((id) => getShowcaseConfig(id)?.weight ?? 1);
|
||||
|
||||
const originalRect = Element.prototype.getBoundingClientRect;
|
||||
@@ -272,7 +273,7 @@ describe("ProjectReel: qual versão entra", () => {
|
||||
expect(reelEl()).toBeNull();
|
||||
const list = listEl() as HTMLElement;
|
||||
expect(list).not.toBeNull();
|
||||
expect(list.querySelectorAll("li[data-device='desktop']")).toHaveLength(5);
|
||||
expect(list.querySelectorAll("li[data-device='desktop']")).toHaveLength(6);
|
||||
expect(list.querySelector(".ds-phone")).toBeNull();
|
||||
expect(list).not.toHaveAttribute("data-pending");
|
||||
});
|
||||
@@ -285,7 +286,7 @@ describe("ProjectReel: qual versão entra", () => {
|
||||
expect(reelEl()).toBeNull();
|
||||
expect(
|
||||
(listEl() as HTMLElement).querySelectorAll("li[data-device='mobile']"),
|
||||
).toHaveLength(5);
|
||||
).toHaveLength(6);
|
||||
});
|
||||
|
||||
it("path: phone width and reduced motion at once -> still the list", () => {
|
||||
@@ -330,13 +331,13 @@ describe("ProjectReel: qual versão entra", () => {
|
||||
renderReel();
|
||||
expect(
|
||||
(listEl() as HTMLElement).querySelectorAll("li[data-device='desktop']"),
|
||||
).toHaveLength(5);
|
||||
).toHaveLength(6);
|
||||
|
||||
changeMedia(MOBILE_QUERY, true);
|
||||
|
||||
expect(
|
||||
(listEl() as HTMLElement).querySelectorAll("li[data-device='mobile']"),
|
||||
).toHaveLength(5);
|
||||
).toHaveLength(6);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -780,7 +781,7 @@ describe("ProjectReel: rolagem suave até um projeto", () => {
|
||||
([options]) => options.top as number,
|
||||
);
|
||||
const finalTop = tops[tops.length - 1];
|
||||
// o destino da Lavação (2º projeto) fica bem antes do da AS Serviços (último)
|
||||
// o destino da Lavação (2º projeto) fica bem antes do da AS Serviços (5º)
|
||||
expect(finalTop).toBeLessThan(reelTopFor(4));
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user