Adjusted typography, styles, and other visual elements to ensure consistent layouts
This commit is contained in:
@@ -111,6 +111,15 @@ const os = require("node:os");
|
||||
await page.evaluate(() => { window.fixtureOpportunitiesDelay = 0; });
|
||||
assert.equal(await page.evaluate(() => window.fixtureContactQueries.length), queriesBeforeOpportunities, "Opportunity lookup must reuse the person's PartyNumber without searching contacts");
|
||||
assert.equal(await contactOpportunities.locator("tbody tr").count(), 6);
|
||||
const presentation = await contactOpportunities.locator("table").evaluate(table => ({
|
||||
marker: table.getAttribute("data-table-layout"),
|
||||
textHeader: getComputedStyle(table.querySelector("th")).textAlign,
|
||||
moneyHeader: getComputedStyle(table.querySelector('th[data-align="money"]')).textAlign,
|
||||
moneyCell: getComputedStyle(table.querySelector('td[data-align="money"]')).textAlign,
|
||||
nowrap: getComputedStyle(table.querySelector(".opportunities-extension-sort-label")).whiteSpace
|
||||
}));
|
||||
assert.deepEqual(presentation,{marker:"standard",textHeader:"left",moneyHeader:"right",moneyCell:"right",nowrap:"nowrap"});
|
||||
await page.screenshot({path:path.join(output,"shared-table.png")});
|
||||
assert.equal(await contactOpportunities.getByRole("link", {name:"Contact opportunity 0",exact:true}).getAttribute("target"), "_blank");
|
||||
assert.ok((await contactOpportunities.getByRole("link", {name:"Contact opportunity 0",exact:true}).getAttribute("href")).endsWith("?puid=CONTACT0"));
|
||||
assert.deepEqual((await page.evaluate(()=>window.fixtureOpportunitiesByContact)).map(url=>new URL(url).searchParams.get("offset")), ["0","5"]);
|
||||
|
||||
Reference in New Issue
Block a user