mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-12 07:42:08 +01:00
d97e36f6d7
includes: - easier repo declaration for playwright tests by @Gusted - full backend build for pushing Git repos by @Gusted - playwright testing (which fails with the current diff algorithm, but passes with the new) - disable eslint rule for conditional expect, because it defeats the purpose (working around it would result in much more complex test code in our cases)
40 lines
1.1 KiB
YAML
40 lines
1.1 KiB
YAML
name: e2e
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- Makefile
|
|
- playwright.config.js
|
|
- .forgejo/workflows/e2e.yml
|
|
- tests/e2e/**
|
|
- web_src/js/**
|
|
|
|
jobs:
|
|
test-e2e:
|
|
if: ${{ !startsWith(vars.ROLE, 'forgejo-') }}
|
|
runs-on: docker
|
|
container:
|
|
image: 'code.forgejo.org/oci/node:20-bookworm'
|
|
steps:
|
|
- uses: https://code.forgejo.org/actions/checkout@v4
|
|
- uses: https://code.forgejo.org/actions/setup-go@v4
|
|
with:
|
|
go-version-file: "go.mod"
|
|
- run: |
|
|
apt-get -qq update
|
|
apt-get -qq install -q sudo git git-lfs
|
|
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 backend'
|
|
- run: |
|
|
su forgejo -c 'make generate test-e2e-sqlite'
|
|
timeout-minutes: 40
|
|
env:
|
|
DEPS_PLAYWRIGHT: 1
|
|
USE_REPO_TEST_DIR: 1
|