feat: add Playwright testing framework configuration and tests #71

Merged
jank merged 48 commits from feature/add-playwright into main 2025-01-17 13:34:52 +00:00
2 changed files with 7 additions and 25 deletions
Showing only changes of commit 1daed7ec65 - Show all commits

View file

@ -10,29 +10,6 @@ jobs:
test: test:
timeout-minutes: 60 timeout-minutes: 60
runs-on: ubuntu-latest runs-on: ubuntu-latest
services:
postgres-employee:
container_name: postgres_employee
image: postgres:13.3
environment:
POSTGRES_DB: employee_db
POSTGRES_USER: employee
POSTGRES_PASSWORD: secret
ports:
- "5432:5432"
employee:
container_name: employee
image: berndheidemann/employee-management-service:1.1.3
# image: berndheidemann/employee-management-service_without_keycloak:1.1
environment:
spring.datasource.url: jdbc:postgresql://postgres-employee:5432/employee_db
spring.datasource.username: employee
spring.datasource.password: secret
ports:
- "8089:8089"
depends_on:
- postgres-employee
steps: steps:
# Checkout the repository # Checkout the repository
@ -43,6 +20,9 @@ jobs:
with: with:
node-version: lts/* node-version: lts/*
- name: Start container for api
run: docker compose up -d
# Install project dependencies # Install project dependencies
- name: Install dependencies - name: Install dependencies
run: npm ci run: npm ci
@ -67,6 +47,10 @@ jobs:
env: env:
CI: true # Ensures Playwright runs in CI mode CI: true # Ensures Playwright runs in CI mode
- name: Stop container for api
run: docker compose up -d
# Upload Playwright report # Upload Playwright report
- uses: actions/upload-artifact@v3 - uses: actions/upload-artifact@v3
if: ${{ !cancelled() }} if: ${{ !cancelled() }}

View file

@ -10,8 +10,6 @@ services:
POSTGRES_DB: employee_db POSTGRES_DB: employee_db
POSTGRES_USER: employee POSTGRES_USER: employee
POSTGRES_PASSWORD: secret POSTGRES_PASSWORD: secret
ports:
- "5432:5432"
employee: employee:
container_name: employee container_name: employee