# Test info

- Name: Verify feature link case >> ALC_OFF_002 - Verify link case manually for request with full match case (never been linked before).
- Location: /root/code/portal-automation-test/tests/link-case/link-case-off/alc-001-002.spec.ts:176:9

# Error details

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

  Expected an image 1428px by 50px, received 1452px by 50px. 5164 pixels (ratio 0.08 of all image pixels) are different.

Expected: /root/code/portal-automation-test/tests/link-case/link-case-off/alc-001-002.spec.ts-snapshots/automation-off-request-unread-chromium-linux.png
Received: /root/code/portal-automation-test/test-results/tests-link-case-link-case--7f443-e-never-been-linked-before--chromium/automation-off-request-unread-34-actual.png
    Diff: /root/code/portal-automation-test/test-results/tests-link-case-link-case--7f443-e-never-been-linked-before--chromium/automation-off-request-unread-34-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/link-case/link-case-off/alc-001-002.spec.ts:113:13
    at /root/code/portal-automation-test/tests/link-case/link-case-off/alc-001-002.spec.ts:108:9
```

# Page snapshot

```yaml
- complementary:
  - img
  - link "Business Link Case Off First Portal QA":
    - /url: /
    - paragraph: Business Link Case Off First
    - 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 [disabled]:
    - img
  - button:
    - img
  - img
  - text: Link Case Off Second shared details about Linkcaseoff790 Test942 Letter of Protection 4 seconds ago
  - img
  - text: Link Case Off Second shared some information about Linkcaseoff498 Test603 Letter of Protection. Find out what it says. 2 minutes 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
  - heading "New Request" [level=4]
  - img
  - paragraph: Pause notifications...
  - list:
    - listitem: For 30 minutes
    - listitem: For 1 hour
    - listitem: For 2 hours
    - listitem: Until tomorrow
  - img
  - heading "Link Case Off Second shared details about Linkcaseoff790 Test942 Letter of Protection" [level=5]
  - paragraph: "#300004Letter of Protection - ref: Linkcaseoff790 Test942"
  - img
  - button "0 Cart":
    - img
    - text: 0 Cart
  - text: Feedback
  - img
  - link "Open user menu":
    - /url: "#"
    - text: Link Case Off
- img
- text: "Shared Requests Stay In Sync: Real-Time Client Request Sharing & Collaboration"
- img
- text: Any requests shared with you will be instantly available here. This means you'll always have real-time access to the latest details, keeping you and your business associates on the same page. More... All 1
- img
- text: Active 1
- img
- text: Reference
- img
- text: Archived
- img
- text: Show
- textbox: "10"
- text: entries
- button "Filter":
  - img
  - text: Filter
- img
- textbox "Search...": Linkcaseoff790 Test942
- img
- table:
  - rowgroup:
    - 'row "Pin Request #  Request Type  Client Name  Shared From  Creator  Directed To  Status  Status Details "':
      - cell "Pin"
      - 'cell "Request # "'
      - cell "Request Type "
      - cell "Client Name "
      - cell "Shared From "
      - cell "Creator "
      - cell "Directed To "
      - cell "Status "
      - cell "Status Details "
  - rowgroup:
    - row "New Unfiled 300004 Letter of Protection Linkcaseoff790 Test942 Business Link Case Off Second Business Link Case Off Second Business Link Case Off First Open Awaiting":
      - cell "New Unfiled":
        - img
        - text: New Unfiled
      - cell "300004":
        - link "300004":
          - /url: https://qa.loprx.com/requests/300004
      - cell "Letter of Protection":
        - link "Letter of Protection":
          - /url: https://qa.loprx.com/requests/300004
          - img
          - text: Letter of Protection
      - cell "Linkcaseoff790 Test942":
        - link "Linkcaseoff790 Test942":
          - /url: https://qa.loprx.com/requests/300004
      - cell "Business Link Case Off Second":
        - link "Business Link Case Off Second":
          - /url: https://qa.loprx.com/requests/300004
      - cell "Business Link Case Off Second":
        - link "Business Link Case Off Second":
          - /url: https://qa.loprx.com/requests/300004
      - cell "Business Link Case Off First":
        - link "Business Link Case Off First":
          - /url: /requests/300004
      - cell "Open":
        - link "Open":
          - /url: https://qa.loprx.com/requests/300004
      - cell "Awaiting":
        - link "Awaiting":
          - /url: https://qa.loprx.com/requests/300004
- paragraph: Showing 1 to 1 of 1 entries
```

# 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 | }
```