Skip to content

Automated tests are failingΒ #6499

@iotux

Description

@iotux

πŸ“‘ I have found these related issues/pull requests

I have found issue #5583, which is related, but it didnt make me any wiser

πŸ›‘οΈ Security Policy

πŸ“ Description

The tests fail with the error expect(page.getByTestId("monitor-status")).toHaveText("up", { ignoreCase: true });. This indicates that the monitor is not up as expected. The issue seems to be related to the e2e test framework, as the tests fail even with a single comment line change in the code.

πŸ‘Ÿ Reproduction steps

Run the e2e tests with npm run test-e2e.
Also applies to automated tests at PR requests

πŸ‘€ Expected behavior

The e2e tests should pass.

πŸ˜“ Actual Behavior

The e2e tests fail with the error expect(page.getByTestId("monitor-status")).toHaveText("up", { ignoreCase: true });.

🐻 Uptime-Kuma Version

2.0.2

πŸ’» Operating System and Arch

Ubuntu 24.10

🌐 Browser

Chromium 1.39.0 (via Playwright)

πŸ–₯️ Deployment Environment

  • Runtime Environment:
    • Node.js: Version 23.11.2 (LTS: No)
  • Database:
    • SQLite: Embedded
  • Database Storage:
    • Filesystem:
      • Linux: ext4
    • Storage Medium: NVMe
  • Uptime Kuma Setup:
    • Number of monitors: 1

πŸ“ Relevant log output

Running 16 tests using 1 worker                                                                                                   β”‚
[WebServer] 2025-12-17T14:43:34+01:00 [MONITOR] WARN: Monitor #1 'New Monitor': Pending: Group empty | Max retries: 0 | Retry: 0  β”‚
| Retry Interval: 60 seconds | Type: group                                                                                        β”‚
[WebServer] 2025-12-17T14:43:51+01:00 [MONITOR] WARN: Monitor #1 'Example DNS NS': Failing: Servers: hera.ns.cloudflare.com |     β”‚
elliott.ns.cloudflare.com | Interval: 60 seconds | Type: dns | Down Count: 0 | Resend Interval: 0                                 β”‚
  1) [specs] β€Ί monitor-form.spec.js:48:9 β€Ί Monitor Form β€Ί successful condition ─────────────────────                              β”‚
                                                                                                                                  β”‚
    Error: expect(locator).toHaveText(expected)                                                                                   β”‚
                                                                                                                                  β”‚
    Locator: getByTestId('monitor-status')                                                                                        β”‚
    Expected string: "up"                                                                                                         β”‚
    Received string: "Down"                                                                                                       β”‚
    Call log:                                                                                                                     β”‚
      - expect.toHaveText with timeout 5000ms                                                                                     β”‚
      - waiting for getByTestId('monitor-status')                                                                                 β”‚
      -   locator resolved to <span data-v-f6ec8efa="" data-testid="monitor-status" …>Unknown</span>                              β”‚
      -   unexpected value "Unknown"                                                                                              β”‚
      -   locator resolved to <span data-v-f6ec8efa="" data-testid="monitor-status" …>Down</span>                                 β”‚
      -   unexpected value "Down"                                                                                                 β”‚
      -   locator resolved to <span data-v-f6ec8efa="" data-testid="monitor-status" …>Down</span>                                 β”‚
      -   unexpected value "Down"                                                                                                 β”‚
                                                                                                                                  β”‚
                                                                                                                                  β”‚
      74 |         await page.waitForURL("/dashboard/*");                                                                         β”‚
      75 |                                                                                                                        β”‚
    > 76 |         expect(page.getByTestId("monitor-status")).toHaveText("up", { ignoreCase: true });                             β”‚
         |                                                    ^                                                                   β”‚
      77 |                                                                                                                        β”‚
      78 |         await screenshot(testInfo, page);                                                                              β”‚
      79 |     });                                                                                                                β”‚
                                                                                                                                  β”‚
        at /home/eigilb/Public/uptime-kuma-dev/test/e2e/specs/monitor-form.spec.js:76:52                                          β”‚
                                                                                                                                  β”‚
[WebServer] 2025-12-17T14:44:02+01:00 [MONITOR] WARN: Monitor #1 'Example DNS NS': Failing: Servers: hera.ns.cloudflare.com |     β”‚
elliott.ns.cloudflare.com | Interval: 60 seconds | Type: dns | Down Count: 0 | Resend Interval: 0                                 β”‚
[WebServer] 2025-12-17T14:44:07+01:00 [MONITOR] WARN: Monitor #1 'Monitor for Status Page': Failing: Request failed with status   β”‚
code 404 | Interval: 60 seconds | Type: http | Down Count: 0 | Resend Interval: 0                                                 β”‚
  1 failed                                                                                                                        β”‚
    [specs] β€Ί monitor-form.spec.js:48:9 β€Ί Monitor Form β€Ί successful condition ──────────────────────                              β”‚
  15 passed (50.5s)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions