diff options
author | Kyle D <kdumontnu@gmail.com> | 2022-09-02 15:18:23 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-02 15:18:23 -0400 |
commit | c8ded77680db7344c8dc1ccee76bce0b4e02e103 (patch) | |
tree | bc63678ef62dc71ce68b29eeaf019c45cdb12034 /.drone.yml | |
parent | 5710ff343c9f16119ddbff06044e5d61388baa22 (diff) | |
download | gitea-c8ded77680db7344c8dc1ccee76bce0b4e02e103.tar.gz gitea-c8ded77680db7344c8dc1ccee76bce0b4e02e103.zip |
Kd/ci playwright go test (#20123)
* Add initial playwright config
* Simplify Makefile
* Simplify Makefile
* Use correct config files
* Update playwright settings
* Fix package-lock file
* Don't use test logger for e2e tests
* fix frontend lint
* Allow passing TEST_LOGGER variable
* Init postgres database
* use standard gitea env variables
* Update playwright
* update drone
* Move empty env var to commands
* Cleanup
* Move integrations to subfolder
* tests integrations to tests integraton
* Run e2e tests with go test
* Fix linting
* install CI deps
* Add files to ESlint
* Fix drone typo
* Don't log to console in CI
* Use go test http server
* Add build step before tests
* Move shared init function to common package
* fix drone
* Clean up tests
* Fix linting
* Better mocking for page + version string
* Cleanup test generation
* Remove dependency on gitea binary
* Fix linting
* add initial support for running specific tests
* Add ACCEPT_VISUAL variable
* don't require git-lfs
* Add initial documentation
* Review feedback
* Add logged in session test
* Attempt fixing drone race
* Cleanup and bump version
* Bump deps
* Review feedback
* simplify installation
* Fix ci
* Update install docs
Diffstat (limited to '.drone.yml')
-rw-r--r-- | .drone.yml | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/.drone.yml b/.drone.yml index 57c888a7d9..93a471fae1 100644 --- a/.drone.yml +++ b/.drone.yml @@ -500,6 +500,75 @@ steps: --- kind: pipeline +type: docker +name: testing-e2e + +platform: + os: linux + arch: amd64 + +depends_on: + - compliance + +trigger: + event: + - pull_request + +volumes: + - name: deps + temp: {} + +services: + - name: pgsql + pull: default + image: postgres:10 + environment: + POSTGRES_DB: testgitea-e2e + POSTGRES_PASSWORD: postgres + POSTGRES_INITDB_ARGS: --encoding=UTF8 --lc-collate='en_US.UTF-8' --lc-ctype='en_US.UTF-8' + +steps: + - name: deps-frontend + image: node:16 + pull: always + commands: + - make deps-frontend + + - name: build-frontend + image: node:16 + commands: + - make frontend + depends_on: [deps-frontend] + + - name: deps-backend + image: golang:1.18 + pull: always + commands: + - make deps-backend + volumes: + - name: deps + path: /go + + # TODO: We should probably build all dependencies into a test image + - name: test-e2e + image: mcr.microsoft.com/playwright:v1.23.1-focal + commands: + - curl -sLO https://go.dev/dl/go1.18.linux-amd64.tar.gz && tar -C /usr/local -xzf go1.18.linux-amd64.tar.gz + - groupadd --gid 1001 gitea && useradd -m --gid 1001 --uid 1001 gitea + - apt-get -qq update && apt-get -qqy install build-essential + - export TEST_PGSQL_SCHEMA='' + - ./build/test-env-prepare.sh + - su gitea bash -c "export PATH=$PATH:/usr/local/go/bin && timeout -s ABRT 40m make test-e2e-pgsql" + environment: + GOPROXY: https://goproxy.io + GOSUMDB: sum.golang.org + USE_REPO_TEST_DIR: 1 + TEST_PGSQL_DBNAME: 'testgitea-e2e' + DEBIAN_FRONTEND: noninteractive + depends_on: [build-frontend, deps-backend] + +--- +kind: pipeline name: update_translations platform: |