Files
logseq/clj-e2e
Mega Yu 1fa5b83b11 chore(deps): update bb.edn dependencies to latest versions
- cheshire 5.12.0 -> 6.1.0
- org.babashka/cli 0.2.23/0.7.53 -> 0.8.67
- org.babashka/http-server 0.1.13 -> 0.1.14
- slipset/deps-deploy 0.2.1 -> 0.2.2
- logseq/bb-tasks sha 70d3edeb/1d429e22 -> acb3d3d5
- clj-kondo pod 2024.09.27 -> 2026.01.19
- org.babashka/fswatcher pod 0.0.3 -> 0.0.7
- org.babashka/go-sqlite3 pod 0.1.0 -> 0.3.13
2026-03-18 15:52:12 +08:00
..
2025-04-24 01:13:28 +08:00

e2e

e2e tests for Logseq app.

Prerequisites

  • The app's JS and CSS assets are built and located at ../static/.
  • Babashka is installed.

Setup

Serve the static assets (default port 3002):

$ bb serve

To use a custom port:

$ bb serve --port 3001
$ bb serve -p 3001

Running Tests

Run all tests (namespaces ending in -basic-test):

$ bb test

Run a single test namespace:

$ bb test -n logseq.e2e.editor-basic-test

Run a single test function:

$ bb test -v logseq.e2e.editor-basic-test/toggle-between-page-and-block

Filter by metadata tag (e.g. ^:focus):

$ bb test -i focus

Combine namespace and tag filters:

$ bb test -n logseq.e2e.editor-basic-test -i focus

Run tests against a custom port:

$ bb test -p 3001

Run tests and serve together (starts both in parallel):

$ bb dev
$ bb dev -p 3001

How -i Works

The -i/--include flag is a cognitect test-runner option. It filters tests by Clojure metadata key. Add ^:focus to any deftest and pass -i focus to run only those tests:

(deftest ^:focus my-test
  ...)

RTC Tests

Run RTC extra tests (served + tested in parallel):

$ bb run-rtc-extra-test
$ bb run-rtc-extra-part2-test

Debugging

When tests fail, clj-e2e/e2e-dump/ contains console logs and screenshots.