1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-12-25 13:19:37 -05:00

[CI] Forgejo Actions e2e tests

(cherry picked from commit 430f7d6519)
(cherry picked from commit b33f3e2fe8)
(cherry picked from commit 5d4f9e4716)
(cherry picked from commit 33b4f02d90)
(cherry picked from commit fe783424e1)
This commit is contained in:
Earl Warren 2024-01-03 15:33:47 +01:00
parent 82395a1f72
commit 38c3d6c423
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -0,0 +1,37 @@
name: e2e
on:
pull_request:
paths:
- Makefile
- .forgejo/workflows/e2e.yml
- tests/e2e/**
jobs:
test-e2e:
if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
runs-on: docker
container:
image: 'docker.io/node:20-bookworm'
steps:
- uses: https://code.forgejo.org/actions/checkout@v4
- uses: https://code.forgejo.org/actions/setup-go@v4
with:
go-version: "~1.21"
check-latest: true
- run: |
apt-get -qq update
apt-get -qq install -q sudo
sed -i -e 's/%sudo.*/%sudo ALL=(ALL:ALL) NOPASSWD:ALL/' /etc/sudoers
git config --add safe.directory '*'
adduser --quiet --comment forgejo --disabled-password forgejo
adduser forgejo sudo
chown -R forgejo:forgejo .
- run: |
su forgejo -c 'make deps-frontend frontend deps-backend'
- run: |
su forgejo -c 'make test-e2e-sqlite'
timeout-minutes: 40
env:
DEPS_PLAYWRIGHT: 1
USE_REPO_TEST_DIR: 1