mirror of
https://github.com/LD-Reborn/Berufsschule_HAM.git
synced 2025-12-20 06:51:55 +00:00
45 lines
1.0 KiB
YAML
45 lines
1.0 KiB
YAML
name: E2E Tests
|
|
|
|
on:
|
|
push:
|
|
branches: [ "*" ]
|
|
# optionally:
|
|
# workflow_dispatch:
|
|
|
|
jobs:
|
|
selenium-tests:
|
|
runs-on: ubuntu-latest
|
|
|
|
services:
|
|
selenium:
|
|
image: selenium/standalone-chromium
|
|
ports:
|
|
- 4444:4444
|
|
options: >-
|
|
--shm-size=2g
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup .NET
|
|
uses: actions/setup-dotnet@v4
|
|
with:
|
|
dotnet-version: '8.0.x'
|
|
|
|
- name: Restore dependencies
|
|
run: dotnet restore src/
|
|
|
|
- name: Build solution
|
|
run: dotnet build src/ --configuration Release --no-restore
|
|
|
|
- name: Run Selenium tests
|
|
env:
|
|
SELENIUM_HUB_URL: http://localhost:4444/wd/hub
|
|
run: dotnet test tests/Berufsschule_HAM.E2ETests/ --logger "trx;LogFileName=test-results.trx"
|
|
|
|
- name: Upload test results
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: selenium-test-results
|
|
path: "**/TestResults/*.trx" |