Add sync test (#678)

This commit is contained in:
Sung 2025-09-28 22:25:34 -07:00 committed by GitHub
commit a26037f83a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 3891 additions and 1 deletions

View file

@ -47,3 +47,7 @@ jobs:
- name: Test app
run: |
make test-api
- name: Test e2e
run: |
make test-e2e

1
.gitignore vendored
View file

@ -4,3 +4,4 @@
*.log
node_modules
/test
tmp

View file

@ -30,7 +30,7 @@ endif
.PHONY: install-js
## test
test: test-cli test-api
test: test-cli test-api test-e2e
.PHONY: test
test-cli:
@ -43,6 +43,11 @@ test-api:
@(${currentDir}/scripts/server/test-local.sh)
.PHONY: test-api
test-e2e:
@echo "==> running E2E test"
@(${currentDir}/scripts/e2e/test.sh)
.PHONY: test-e2e
test-selfhost:
@echo "==> running a smoke test for self-hosting"

3867
pkg/e2e/sync_test.go Normal file

File diff suppressed because it is too large Load diff

13
scripts/e2e/test.sh Executable file
View file

@ -0,0 +1,13 @@
#!/bin/bash
set -eux
dir=$(dirname "${BASH_SOURCE[0]}")
basePath=$(realpath "$dir/../../")
set -a
source "$basePath/pkg/server/.env.test"
set +a
pushd "$basePath"/pkg/e2e
go test --tags "fts5" ./... -p 1
popd