oneuptime/E2E
Nawaz Dhandala 7ff0da5ab5
Some checks are pending
Push Release Images to Docker Hub and GitHub Container Registry / app-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / accounts-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / ai-agent-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / publish-npm-packages (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / generate-build-number (push) Waiting to run
Push Release Images to Docker Hub and GitHub Container Registry / read-version (push) Waiting to run
Push Release Images to Docker Hub and GitHub Container Registry / helm-chart-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / mcp-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / nginx-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / e2e-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / isolated-vm-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / home-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / test-server-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / otel-collector-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / status-page-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / test-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / probe-ingest-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / server-monitor-ingest-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / telemetry-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / incoming-request-ingest-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / probe-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / admin-dashboard-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / dashboard-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / docs-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / worker-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / workflow-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / publish-terraform-provider (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / api-reference-docker-image-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / Push release tags before GitHub release (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / infrastructure-agent-deploy (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / test-e2e-release-saas (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / test-e2e-release-self-hosted (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / Create draft GitHub release (push) Blocked by required conditions
Push Release Images to Docker Hub and GitHub Container Registry / Publish GitHub release (push) Blocked by required conditions
fix: Update navigation for Enterprise dropdown and adjust Request Demo link
2026-01-06 11:19:07 +00:00
..
Tests fix: Update navigation for Enterprise dropdown and adjust Request Demo link 2026-01-06 11:19:07 +00:00
.gitignore Remove unused files and dependencies 2023-12-12 15:03:08 +00:00
Config.ts refactor: Update symbol type to use lowercase 'symbol' in ColumnAccessControl files 2024-06-14 12:09:53 +01:00
Dockerfile.tpl feat: Reduce npm fetch retry timeout values in Dockerfiles 2025-12-16 13:30:12 +00:00
package-lock.json chore: npm audit fix 2025-11-25 01:48:46 +00:00
package.json feat: Add repository field to package.json files across the project 2025-12-11 21:31:52 +00:00
playwright.config.ts Refactor comments across multiple files to improve clarity and consistency 2025-10-02 11:53:55 +01:00
README.md fix: update link selector for OneUptime in Landing.spec.ts 2025-12-05 11:03:33 +00:00
tsconfig.json Update tsconfig.json files with resolveJsonModule option 2024-04-08 14:03:07 +01:00

E2E Tests

End-to-end tests for OneUptime using Playwright.

Prerequisites

  • Node.js (v18 or higher recommended)
  • npm

Installation

cd E2E
npm install

This will automatically install Playwright browsers and dependencies via the preinstall script.

Configuration

The tests use environment variables for configuration. Set the following variables before running tests in config.env:

Variable Description Default
HOST The hostname to test against localhost
HTTP_PROTOCOL Protocol to use (http or https) http
BILLING_ENABLED Enable billing-related tests false
E2E_TEST_IS_USER_REGISTERED Whether a test user is already registered false
E2E_TEST_REGISTERED_USER_EMAIL Email of the registered test user -
E2E_TEST_REGISTERED_USER_PASSWORD Password of the registered test user -
E2E_TEST_STATUS_PAGE_URL URL of a status page to test -
E2E_TESTS_FAILED_WEBHOOK_URL Webhook URL to call on test failure -

Example

export HOST=staging.oneuptime.com
export HTTP_PROTOCOL=https
export BILLING_ENABLED=true

Running Tests

Run all tests

npm test

Run tests in debug mode

npm run debug-tests

Run specific test file

npx playwright test Tests/Home/Landing.spec.ts

Run tests for a specific browser

# Chromium only
npx playwright test --project=chromium

# Firefox only
npx playwright test --project=firefox

Run tests with UI mode

npx playwright test --ui

Run a specific test by name

npx playwright test -g "oneUptime link navigate to homepage"

Test Structure

E2E/
├── Tests/
│   ├── Accounts/       # Account-related tests (login, registration)
│   ├── App/            # Main application tests
│   ├── Home/           # Homepage tests
│   ├── IncomingRequestIngest/
│   ├── ProbeIngest/
│   ├── StatusPage/     # Status page tests
│   └── TelemetryIngest/
├── Config.ts           # Environment configuration
├── playwright.config.ts # Playwright configuration
└── package.json

Viewing Test Reports

After running tests, an HTML report is generated. Open it with:

npx playwright show-report

Test Configuration

The Playwright configuration (playwright.config.ts) includes:

  • Timeout: 240 seconds per test
  • Retries: 3 retries on failure
  • Browsers: Chromium and Firefox
  • Tracing: Enabled for debugging failed tests

Debugging

View traces

When tests fail, traces are collected. View them with:

npx playwright show-trace test-results/<test-name>/trace.zip

Run in headed mode

npx playwright test --headed

Slow down execution

npx playwright test --headed --slow-mo=1000

CI/CD

For CI environments, the CI environment variable is automatically detected:

  • test.only usage will fail the build
  • Parallel test execution is disabled (workers: 1)

Troubleshooting

Playwright browsers not installed

npx playwright install
npx playwright install-deps

Clear and reinstall dependencies

npm run clear-modules