forked from trent_larson/crowd-funder-for-time-pwa
fix problem with "Affirm Delivery" on offer claim page, plus other look-and-feel tweaks
This commit is contained in:
@@ -16,7 +16,7 @@ test('New offers for another user', async ({ page }) => {
|
||||
await expect(page.locator('div[role="alert"] button > svg.fa-xmark')).toBeHidden(); // ensure alert is gone
|
||||
|
||||
// show buttons to make offers directly to people
|
||||
await page.getByRole('button').filter({ hasText: /Show Given Hours/i }).click();
|
||||
await page.getByRole('button').filter({ hasText: /See Hours/i }).click();
|
||||
|
||||
// make an offer directly to user 1
|
||||
// Generate a random string of 3 characters, skipping the "0." at the beginning
|
||||
@@ -50,7 +50,7 @@ test('New offers for another user', async ({ page }) => {
|
||||
await offerNumElem.click();
|
||||
|
||||
await expect(page.getByText('New Offers To You', { exact: true })).toBeVisible();
|
||||
await page.getByTestId('showOffersToUser').click();
|
||||
await page.getByTestId('showOffersToUser').locator('div > svg.fa-chevron-right').click();
|
||||
// note that they show in reverse chronologicalorder
|
||||
await expect(page.getByText(`help of ${randomString2} from #000`)).toBeVisible();
|
||||
await expect(page.getByText(`help of ${randomString1} from #000`)).toBeVisible();
|
||||
@@ -62,7 +62,8 @@ test('New offers for another user', async ({ page }) => {
|
||||
// now find the "Click to keep all above as new offers" after that list item and click it
|
||||
const liElem = page.locator('li').filter({ hasText: `help of ${randomString2} from #000` });
|
||||
await liElem.hover();
|
||||
const keepAboveAsNew = liElem.locator('div').filter({ hasText: /keep all above/ });
|
||||
const keepAboveAsNew = await liElem.locator('div').filter({ hasText: /keep all above/ });
|
||||
|
||||
await keepAboveAsNew.click();
|
||||
|
||||
// now see that only one offer is shown as new
|
||||
@@ -71,7 +72,7 @@ test('New offers for another user', async ({ page }) => {
|
||||
await expect(offerNumElem).toHaveText('1');
|
||||
await offerNumElem.click();
|
||||
await expect(page.getByText('New Offer To You', { exact: true })).toBeVisible();
|
||||
await page.getByTestId('showOffersToUser').click();
|
||||
await page.getByTestId('showOffersToUser').locator('div > svg.fa-chevron-right').click();
|
||||
|
||||
// now see that no offers are shown as new
|
||||
await page.goto('./');
|
||||
|
||||
Reference in New Issue
Block a user