# Test info

- Name: Feature case for request-listing >> REQ_041 - Verify when adding a request by hovering over the Case ID from two different business
- Location: /root/code/portal-automation-test/tests/request/function.spec.ts:1347:9

# Error details

```
Error: expect(Buffer).toMatchSnapshot(expected)

  Expected an image 1024px by 550px, received 1304px by 550px. 22935 pixels (ratio 0.04 of all image pixels) are different.

Expected: /root/code/portal-automation-test/tests/request/function.spec.ts-snapshots/list-request-overview-chromium-linux.png
Received: /root/code/portal-automation-test/test-results/tests-request-function-Fea-b154d-from-two-different-business-chromium/list-request-overview-17-actual.png
    Diff: /root/code/portal-automation-test/test-results/tests-request-function-Fea-b154d-from-two-different-business-chromium/list-request-overview-17-diff.png


Call Log:
- Test timeout of 80000ms exceeded
    at verifyScreenshot (/root/code/portal-automation-test/utils/screenshot.ts:22:8)
    at /root/code/portal-automation-test/tests/request/function.spec.ts:1394:13
    at /root/code/portal-automation-test/tests/request/function.spec.ts:1391:9
```

# Page snapshot

```yaml
- complementary:
  - img
  - link "(Portal-Auto-Lawyer) Portal QA":
    - /url: /
    - paragraph: (Portal-Auto-Lawyer)
    - paragraph: Portal QA
  - list:
    - listitem:
      - link "Home":
        - /url: https://qa.loprx.com
        - img
        - text: Home
    - listitem:
      - link "Case":
        - /url: https://qa.loprx.com/cases
        - img
        - text: Case
    - listitem:
      - link "Request":
        - /url: https://qa.loprx.com/requests
        - img
        - text: Request
    - listitem:
      - link "Client":
        - /url: https://qa.loprx.com/clients
        - img
        - text: Client
    - listitem:
      - button "Business/Contact":
        - img
        - text: Business/Contact
    - listitem:
      - button "Inbox/Sent":
        - img
        - text: Inbox/Sent
    - listitem:
      - button "Settings":
        - img
        - text: Settings
  - list:
    - listitem:
      - link "Shared with me":
        - /url: https://qa.loprx.com/shared/requests
        - img
        - text: Shared with me
- banner:
  - button:
    - img
  - button [disabled]:
    - img
  - img
  - text: Link Case First shared some information about New Case 123 Letter of Protection. Find out what it says. 1 week ago
  - img
  - text: What did Tri01 Duc say? Their response to Test Request Letter of Protection is waiting. 6 days ago
  - img
  - text: Link Case First shared details about Third Party Letter of Protection 1 week ago
  - img
  - text: What did Tri01 Duc say? Their response to Test Request Letter of Protection is waiting. 6 days ago
  - textbox "Search..."
  - img
  - img
  - textbox "Search..."
  - img
  - img
  - paragraph: No notifications yet
  - paragraph: When you get notifications, they'll show up here
  - button "Refresh"
  - list:
    - listitem:
      - img
      - paragraph: Pause notifications...
      - list:
        - listitem: For 30 minutes
        - listitem: For 1 hour
        - listitem: For 2 hours
        - listitem: Until tomorrow
    - listitem:
      - img
    - listitem:
      - img
    - listitem:
      - img
    - listitem:
      - img
    - listitem:
      - img
    - listitem:
      - img
  - img
  - button "4 Cart":
    - img
    - text: 4 Cart
  - text: Feedback
  - img
  - link "Open user menu":
    - /url: "#"
    - text: Minh
- img
- text: New Request
- button "Switch to Step-by-Step"
- text: Tips
- img
- text: Welcome to the Fast Track!
- paragraph: This section allows you to submit multiple requests for one or several clients simultaneously, saving you valuable time. Instead of handling requests individually, you can create them for all your clients at once, streamlining your workflow.
- text: More...
- paragraph: "1"
- text: Select an Action
- paragraph: "2"
- text: Identify Client
- paragraph: "3"
- text: Identify a Business
- paragraph: "4"
- text: Create Message
- paragraph: "5"
- text: Share with Others
- checkbox "Apply all"
- text: Apply all
- checkbox "Apply all"
- text: Apply all
- checkbox "Apply all"
- text: Apply all
- checkbox "Apply all" [disabled]
- text: Apply all
- img
- checkbox "Apply all"
- text: Apply all Letter of Protection Test Request (Dat Lawyers) Message Email
- img
- text: Delete Medical Bill Test Request The Vu Law Firm Templated Message Email
- img
- text: Delete Affidavit New Patient Test A Taylor Law Firm Templated Message Email
- img
- text: Delete Others New Patient Test (Portal-Auto-Lawyer) Message Email
- img
- text: Delete
- button "Add more"
- button "Create"
```

# Test source

```ts
   1 | import { expect, Locator, Page } from "@playwright/test";
   2 |
   3 | const DEFAULT_VIEWPORT = { width: 1920, height: 1080 };
   4 |
   5 | export const verifyScreenshot = async (
   6 |     snapshotName: string,
   7 |     target: Page | Locator,
   8 |     mask?: Locator[],
   9 |     tolerance: number = 0,
  10 |     viewport: { width: number; height: number } = DEFAULT_VIEWPORT
  11 | ) => {
  12 |     const page = 'page' in target ? target.page() : target;
  13 |     await page.setViewportSize(viewport);
  14 |
  15 |     await page.waitForLoadState('domcontentloaded');
  16 |     await page.waitForTimeout(1_000);
  17 |
  18 |     await expect(async () => {
  19 |         expect(await target.screenshot({ mask })).toMatchSnapshot(snapshotName, {
  20 |             maxDiffPixelRatio: tolerance
  21 |         });
> 22 |     }).toPass();
     |        ^ Error: expect(Buffer).toMatchSnapshot(expected)
  23 | };
  24 |
  25 | export const takeScreenshot = async (snapshotName: string, target: Page | Locator, mask?: Locator[]) => {
  26 |     expect(await target.screenshot({
  27 |         mask
  28 |     })).toMatchSnapshot(snapshotName)
  29 | }
```