Adapt the smoke test to the empty backfill and recovery card
This commit is contained in:
@@ -206,10 +206,11 @@ try {
|
|||||||
() => document.querySelector("#title-lane")?.textContent?.includes("Titles (YouTube)"),
|
() => document.querySelector("#title-lane")?.textContent?.includes("Titles (YouTube)"),
|
||||||
{ timeout: 15000 }
|
{ timeout: 15000 }
|
||||||
);
|
);
|
||||||
check(
|
await page.waitForFunction(
|
||||||
"recovery card renders",
|
() => document.querySelector("#recover-lane")?.textContent?.includes("Recover Discord previews"),
|
||||||
(await page.locator("#recover-lane").textContent())?.includes("Recover Discord previews") === true
|
{ timeout: 15000 }
|
||||||
);
|
);
|
||||||
|
check("recovery card renders", true);
|
||||||
const withMessage = await page.evaluate(async () => {
|
const withMessage = await page.evaluate(async () => {
|
||||||
const response = await fetch("/api/media?kind=video&limit=5");
|
const response = await fetch("/api/media?kind=video&limit=5");
|
||||||
const body = await response.json();
|
const body = await response.json();
|
||||||
@@ -230,7 +231,11 @@ try {
|
|||||||
);
|
);
|
||||||
step("eta tooltips", etaTitles);
|
step("eta tooltips", etaTitles);
|
||||||
check("queue eta tooltip", etaTitles.some(title => title.includes("queue drains in")));
|
check("queue eta tooltip", etaTitles.some(title => title.includes("queue drains in")));
|
||||||
|
if ((await page.locator(".vk-bot-job").count()) === 0) {
|
||||||
|
step("job eta tooltip", "no pending jobs");
|
||||||
|
} else {
|
||||||
check("job eta tooltip", etaTitles.some(title => /starts in .* runs for/.test(title)));
|
check("job eta tooltip", etaTitles.some(title => /starts in .* runs for/.test(title)));
|
||||||
|
}
|
||||||
|
|
||||||
const groups = await page.locator("#bot-tunables details").count();
|
const groups = await page.locator("#bot-tunables details").count();
|
||||||
step("tunable groups", groups);
|
step("tunable groups", groups);
|
||||||
|
|||||||
Reference in New Issue
Block a user