Skip to content

Intentionally fail test #8

Intentionally fail test

Intentionally fail test #8

Workflow file for this run

# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Run automated tests
on:
pull_request:
branches: [ master, '*-develop', 'mainline*' ]
jobs:
testUI:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
runIde: |
export DISPLAY=:99.0
Xvfb -ac :99 -screen 0 1920x1080x24 &
sleep 10
./gradlew runIdeForUiTests &
# TODO: fix for windows is needed, currently Gradle can't process .form files for windows
# - os: windows-latest
# runIde: start gradlew.bat runIdeForUiTests
# - os: macos-latest
# runIde: ./gradlew runIdeForUiTests &
steps:
# Check out the current repository
- name: Fetch Sources
uses: actions/checkout@v4
# Set up Java environment for the next steps
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 17
# Setup Gradle
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4
# Run IDEA prepared for UI testing
- name: Run IDE
run: ${{ matrix.runIde }}
# Wait for IDEA to be started
- name: Health Check
uses: jtalk/url-health-check-action@v4
with:
url: http://127.0.0.1:8082
max-attempts: 15
retry-delay: 30s
# Run tests
- name: Tests
if: matrix.os != 'ubuntu-latest'
run: ./gradlew uiTests
- name: Tests Ubuntu
if: matrix.os == 'ubuntu-latest'
run: |
export DISPLAY=:99.0
./gradlew test -PexcludeTests="**/reference/**,**/linemarker/**,**/inspections/**,**/completion/**,**/actions/**"
# Uncomment if investigation is needed:
# - name: Capture Test Artifacts on Failure
# if: failure() && matrix.os == 'windows-latest'
# run: tar -cvzf video.tgz ./video
# shell: bash
#
# - name: Upload Test Video Artifact
# if: failure() && matrix.os == 'windows-latest'
# uses: actions/upload-artifact@v4
# with:
# name: latest-test-video
# path: video.tgz
# overwrite: true