Skip to content

Test playwright

Test playwright #4

Workflow file for this run

name: Example Tests
# This workflow runs tests for the DevExpress Angular Report Designer frontend.
on:
push:
branches:
- '[0-9]+.[0-9]+.[0-9]+\+' # Matches xx.x.x+ pattern
pull_request:
branches:
- '[0-9]+.[0-9]+.[0-9]+\+' # Matches xx.x.x+ pattern
workflow_dispatch: # Allows manual triggering
env:
NODE_VERSION: '20'
DOTNET_VERSION: '8.0.x'
jobs:
test:
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: 'npm'
cache-dependency-path: |
package-lock.json
angular-report-designer/package-lock.json
- name: Setup Chrome
uses: browser-actions/setup-chrome@v1
with:
chrome-version: stable
- name: Run Tests
shell: pwsh
run: |
try {
& "test/main-test.ps1"
if ($LASTEXITCODE -ne 0) {
Write-Host "❌ Tests failed with exit code: $LASTEXITCODE" -ForegroundColor Red
exit $LASTEXITCODE
}
Write-Host "✅ Tests passed successfully" -ForegroundColor Green
}
catch {
Write-Host "❌ Test execution failed: $($_.Exception.Message)" -ForegroundColor Red
exit 1
}