From 9be2bbb28719c1681cfff104c68b820cd0b386b7 Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Wed, 17 Jun 2026 16:16:00 +0200 Subject: [PATCH 1/9] Remove obsolete Travis CI configuration Travis ran on years-EOL Ubuntu xenial and was effectively dead. Its headless TestFX MAVEN_OPTS (xvfb + glass robot + software prism) are ported into the new _test.yml reusable workflow. Co-Authored-By: Claude Opus 4.8 --- .travis.yml | 19 ------------------- 1 file changed, 19 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 1dc660ef2c..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ -sudo: required -language: java -dist: xenial -jdk: - - openjdk21 - -services: - - xvfb - -before_script: - - if [ "${TRAVIS_OS_NAME}" == "linux" ]; then export DISPLAY=:99.0 && /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16; fi - - MAVEN_OPTS="-Djava.awt.headless=true -Dtestfx.robot=glass -Dtestfx.headless=true -Dprism.order=sw -Dprism.text=t2k -Dtestfx.setup.timeout=2500" - -script: - - mvn clean install - -after_failure: - - find ./ -type d -name "surefire-reports" -print0 | xargs -0 -I {} find {} -iname "*.txt" -type f | xargs cat - - find . -type f -name "*.log" -print0 -exec cat {} \; From 2c701ca98c21cc48fc0ca5b92c259ca8b3ec735a Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Wed, 17 Jun 2026 16:16:00 +0200 Subject: [PATCH 2/9] Overhaul GitHub Actions CI into reusable, per-event workflows Replace the old build.yml / build_latest.yml / four *-docker-image.yml setup with reusable workflows invoked by thin, event-specific callers: Reusable (workflow_call): - _build, _test (unit + TestFX UI under xvfb), _integration-test (Elasticsearch service container), _docker-image (build + publish to ghcr). Event callers: - branch.yml (push, non-master): fast build-only compile check. - pr.yml (pull_request): build gate -> test + integration-test; covers same-repo and fork PRs read-only (plain pull_request, no secrets). - merge.yml (push master): cross-platform matrix build + test + integration-test, and publishes images for changed services (native git-diff detection). - release.yml (push tag): publishes all service images. - report.yml (workflow_run): publishes JUnit results as a check in the base-repo context, so fork PRs get a check too. Tests run as a required gate: a failure fails the job. Also repoint the README CI status badge at merge.yml; the build.yml it referenced is removed here. Co-Authored-By: Claude Opus 4.8 --- .github/CI_VERSIONS.md | 9 +++ .github/actions/setup-java/action.yml | 14 ++++ .github/workflows/_build.yml | 34 ++++++++++ .github/workflows/_docker-image.yml | 54 ++++++++++++++++ .github/workflows/_integration-test.yml | 41 ++++++++++++ .github/workflows/_test.yml | 32 ++++++++++ .../workflows/alarm-logger-docker-image.yml | 63 ------------------ .../workflows/alarm-server-docker-image.yml | 63 ------------------ .github/workflows/branch.yml | 17 +++++ .github/workflows/build.yml | 20 ------ .github/workflows/build_latest.yml | 32 ---------- .github/workflows/merge.yml | 38 +++++++++++ .github/workflows/pr.yml | 22 +++++++ .github/workflows/release.yml | 24 +++++++ .github/workflows/report.yml | 31 +++++++++ .../save-and-restore-docker-image.yml | 52 --------------- .../workflows/scan-server-docker-image.yml | 64 ------------------- README.md | 2 +- 18 files changed, 317 insertions(+), 295 deletions(-) create mode 100644 .github/CI_VERSIONS.md create mode 100644 .github/actions/setup-java/action.yml create mode 100644 .github/workflows/_build.yml create mode 100644 .github/workflows/_docker-image.yml create mode 100644 .github/workflows/_integration-test.yml create mode 100644 .github/workflows/_test.yml delete mode 100644 .github/workflows/alarm-logger-docker-image.yml delete mode 100644 .github/workflows/alarm-server-docker-image.yml create mode 100644 .github/workflows/branch.yml delete mode 100644 .github/workflows/build.yml delete mode 100644 .github/workflows/build_latest.yml create mode 100644 .github/workflows/merge.yml create mode 100644 .github/workflows/pr.yml create mode 100644 .github/workflows/release.yml create mode 100644 .github/workflows/report.yml delete mode 100644 .github/workflows/save-and-restore-docker-image.yml delete mode 100644 .github/workflows/scan-server-docker-image.yml diff --git a/.github/CI_VERSIONS.md b/.github/CI_VERSIONS.md new file mode 100644 index 0000000000..a0aee7580a --- /dev/null +++ b/.github/CI_VERSIONS.md @@ -0,0 +1,9 @@ +# CI version pins + +Some versions used by CI are pinned manually and must be kept current. This +file is the checklist of what needs periodic review and where each pin lives. + +| What | Version | Defined in | Notes | +|------|---------|------------|-------| +| Java (JDK) | `21` | `.github/actions/setup-java/action.yml` | Single source of truth for the CI JDK. Must match `maven.compiler.source`/`maven.compiler.target` in `pom.xml`. Review when the project adopts a new LTS. | +| Elasticsearch | `8.11.2` | `.github/workflows/_integration-test.yml` and `services/save-and-restore/docker-compose.yml` | Service container for the save-and-restore integration tests. Update both files together. | diff --git a/.github/actions/setup-java/action.yml b/.github/actions/setup-java/action.yml new file mode 100644 index 0000000000..5be35778f5 --- /dev/null +++ b/.github/actions/setup-java/action.yml @@ -0,0 +1,14 @@ +name: Set up Java +description: Set up the project's pinned JDK with Maven dependency caching. + +runs: + using: composite + steps: + # Java 21 is the single source of truth for the CI JDK. It must match + # maven.compiler.source/target in pom.xml (currently 21). See + # .github/CI_VERSIONS.md. Bump here when the project moves to a new LTS. + - uses: actions/setup-java@v5 + with: + distribution: temurin + java-version: '21' + cache: maven diff --git a/.github/workflows/_build.yml b/.github/workflows/_build.yml new file mode 100644 index 0000000000..a05b4a4d06 --- /dev/null +++ b/.github/workflows/_build.yml @@ -0,0 +1,34 @@ +name: Build + +on: + workflow_call: + inputs: + os: + description: Runner to build on. + type: string + default: ubuntu-latest + upload-artifacts: + description: Upload the product tarball/zip (used by the master build). + type: boolean + default: false + +permissions: + contents: read + +jobs: + build: + runs-on: ${{ inputs.os }} + steps: + - uses: actions/checkout@v6 + - name: Set up Java + uses: ./.github/actions/setup-java + - name: Build + run: mvn --batch-mode install -DskipTests + - name: Archive build artifacts + if: ${{ inputs.upload-artifacts }} + uses: actions/upload-artifact@v7 + with: + name: Phoebus product ${{ inputs.os }} + path: | + ${{ github.workspace }}/phoebus-product/target/*.tar.gz + ${{ github.workspace }}/phoebus-product/target/*.zip diff --git a/.github/workflows/_docker-image.yml b/.github/workflows/_docker-image.yml new file mode 100644 index 0000000000..9ec69ec559 --- /dev/null +++ b/.github/workflows/_docker-image.yml @@ -0,0 +1,54 @@ +name: Docker image + +on: + workflow_call: + inputs: + image-suffix: + description: Image name under ghcr.io/// (e.g. service-alarm-server). + required: true + type: string + context: + description: Docker build context directory. + required: true + type: string + maven-args: + description: Maven goals/flags for the package step. + type: string + default: --update-snapshots package + +permissions: + contents: read + packages: write + +jobs: + build-and-push-image: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Set up Java + uses: ./.github/actions/setup-java + - name: Build with Maven + run: mvn --batch-mode ${{ inputs.maven-args }} + - name: Login to the registry + uses: docker/login-action@v4 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Extract meta-data for Docker + id: meta + uses: docker/metadata-action@v6 + with: + images: ghcr.io/${{ github.repository }}/${{ inputs.image-suffix }} + - name: Set up Docker Build + uses: docker/setup-buildx-action@v4 + - name: Build and publish the Docker image + uses: docker/build-push-action@v7 + with: + context: ${{ inputs.context }} + push: true + platforms: linux/amd64,linux/arm64 + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + cache-from: type=gha + cache-to: type=gha,mode=max diff --git a/.github/workflows/_integration-test.yml b/.github/workflows/_integration-test.yml new file mode 100644 index 0000000000..f40cb656a9 --- /dev/null +++ b/.github/workflows/_integration-test.yml @@ -0,0 +1,41 @@ +name: Integration test + +on: + workflow_call: + +permissions: + contents: read + +jobs: + integration-test: + runs-on: ubuntu-latest + services: + # TODO swap to testcontainers for integration tests + elasticsearch: + image: docker.elastic.co/elasticsearch/elasticsearch:8.11.2 + env: + discovery.type: single-node + xpack.security.enabled: "false" + ports: + - 9200:9200 + options: >- + --health-cmd "curl -s http://localhost:9200/_cluster/health || exit 1" + --health-interval 10s + --health-timeout 5s + --health-retries 30 + steps: + - uses: actions/checkout@v6 + - name: Set up Java + uses: ./.github/actions/setup-java + - name: Integration tests (Elasticsearch-backed) + run: > + mvn --batch-mode install -P it-tests,docker-tests + -Dspring.profiles.active=IT + -pl services/save-and-restore -am + - name: Upload integration test reports + uses: actions/upload-artifact@v7 + if: always() + with: + name: integration-test-reports + path: services/save-and-restore/target/failsafe-reports/** + if-no-files-found: ignore diff --git a/.github/workflows/_test.yml b/.github/workflows/_test.yml new file mode 100644 index 0000000000..dbd297fb0d --- /dev/null +++ b/.github/workflows/_test.yml @@ -0,0 +1,32 @@ +name: Test + +on: + workflow_call: + +permissions: + contents: read + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Set up Java + uses: ./.github/actions/setup-java + - name: Test + run: > + xvfb-run -a + mvn --batch-mode verify -P ui-tests + env: + MAVEN_OPTS: >- + -Djava.awt.headless=true -Dtestfx.robot=glass -Dtestfx.headless=true + -Dprism.order=sw -Dprism.text=t2k -Dtestfx.setup.timeout=2500 + - name: Upload test reports + uses: actions/upload-artifact@v7 + if: always() + with: + name: test-reports + path: | + **/target/surefire-reports/** + **/target/failsafe-reports/** + if-no-files-found: ignore diff --git a/.github/workflows/alarm-logger-docker-image.yml b/.github/workflows/alarm-logger-docker-image.yml deleted file mode 100644 index 94071123e6..0000000000 --- a/.github/workflows/alarm-logger-docker-image.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: Alarm Logger Docker Image CI - -on: - push: - branches: [ "master" ] - paths: services/alarm-logger/** - tags: - - '**' - -env: - REGISTRY: ghcr.io - IMAGE_NAME: ${{ github.repository }}/service-alarm-logger - -jobs: - build-server: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Maven and Java Action - uses: s4u/setup-maven-action@v1.18.0 - with: - java-version: '21' - maven-version: '3.9.6' - - name: Build - run: mvn --batch-mode install -DskipTests - build-and-push-image: - permissions: - contents: read - packages: write - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - java-version: '21' - distribution: 'temurin' - cache: maven - - name: Build with Maven - run: mvn --batch-mode --update-snapshots package - - name: Login to the registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Extract meta-data for Docker - id: meta - uses: docker/metadata-action@v5 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - name: Set up Docker Build - uses: docker/setup-buildx-action@v3 - - name: Build and publish the Docker image - uses: docker/build-push-action@v5 - with: - context: services/alarm-logger - push: true - platforms: linux/amd64,linux/arm64 - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha - cache-to: type=gha,mode=max diff --git a/.github/workflows/alarm-server-docker-image.yml b/.github/workflows/alarm-server-docker-image.yml deleted file mode 100644 index 4fe2f28281..0000000000 --- a/.github/workflows/alarm-server-docker-image.yml +++ /dev/null @@ -1,63 +0,0 @@ -name: Alarm Server Docker Image CI - -on: - push: - branches: [ "master" ] - paths: services/alarm-server/** - tags: - - '**' - -env: - REGISTRY: ghcr.io - IMAGE_NAME: ${{ github.repository }}/service-alarm-server - -jobs: - build-server: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Maven and Java Action - uses: s4u/setup-maven-action@v1.18.0 - with: - java-version: '21' - maven-version: '3.9.6' - - name: Build - run: mvn --batch-mode install -DskipTests - build-and-push-image: - permissions: - contents: read - packages: write - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - java-version: '21' - distribution: 'temurin' - cache: maven - - name: Build with Maven - run: mvn --batch-mode --update-snapshots package - - name: Login to the registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Extract meta-data for Docker - id: meta - uses: docker/metadata-action@v5 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - name: Set up Docker Build - uses: docker/setup-buildx-action@v3 - - name: Build and publish the Docker image - uses: docker/build-push-action@v5 - with: - context: services/alarm-server - push: true - platforms: linux/amd64,linux/arm64 - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha - cache-to: type=gha,mode=max diff --git a/.github/workflows/branch.yml b/.github/workflows/branch.yml new file mode 100644 index 0000000000..e8c58fb6fa --- /dev/null +++ b/.github/workflows/branch.yml @@ -0,0 +1,17 @@ +name: Branch + +on: + push: + branches-ignore: + - master + +permissions: + contents: read + +concurrency: + group: branch-${{ github.ref }} + cancel-in-progress: true + +jobs: + build: + uses: ./.github/workflows/_build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml deleted file mode 100644 index 00ee599c99..0000000000 --- a/.github/workflows/build.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: Phoebus build - -on: - push: - branches-ignore: - - 'master' - pull_request: - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Maven and Java Action - uses: s4u/setup-maven-action@v1.18.0 - with: - java-version: '21' - maven-version: '3.9.6' - - name: Build - run: mvn --batch-mode install -DskipTests \ No newline at end of file diff --git a/.github/workflows/build_latest.yml b/.github/workflows/build_latest.yml deleted file mode 100644 index 72bc62f3be..0000000000 --- a/.github/workflows/build_latest.yml +++ /dev/null @@ -1,32 +0,0 @@ -name: Phoebus build - -on: - push: - branches: - - master - -jobs: - build: - strategy: - fail-fast: false - matrix: - os: ["ubuntu-latest", "windows-latest", "macos-latest"] - - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - name: Setup Maven and Java Action - uses: s4u/setup-maven-action@v1.18.0 - with: - java-version: '21' - maven-version: '3.9.6' - - name: Build - run: mvn --batch-mode install -DskipTests - - - name: Archive build artifacts - uses: actions/upload-artifact@v4 - with: - name: Phoebus product ${{ matrix.os }} - path: | - ${{ github.workspace }}/phoebus-product/target/*.tar.gz - ${{ github.workspace }}/phoebus-product/target/*.zip diff --git a/.github/workflows/merge.yml b/.github/workflows/merge.yml new file mode 100644 index 0000000000..e0281e87f1 --- /dev/null +++ b/.github/workflows/merge.yml @@ -0,0 +1,38 @@ +name: Merge to master + +on: + push: + branches: + - master + +permissions: + contents: read + +jobs: + build: + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, windows-latest, macos-latest] + uses: ./.github/workflows/_build.yml + with: + os: ${{ matrix.os }} + upload-artifacts: true + test: + uses: ./.github/workflows/_test.yml + integration-test: + uses: ./.github/workflows/_integration-test.yml + + docker-image: + permissions: + contents: read + packages: write + strategy: + fail-fast: false + matrix: + service: [alarm-server, alarm-logger, save-and-restore, scan-server] + uses: ./.github/workflows/_docker-image.yml + with: + image-suffix: service-${{ matrix.service }} + context: services/${{ matrix.service }} + maven-args: ${{ matrix.service == 'scan-server' && '-Pexecutable-jar --update-snapshots package' || '--update-snapshots package' }} diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml new file mode 100644 index 0000000000..9e44092dac --- /dev/null +++ b/.github/workflows/pr.yml @@ -0,0 +1,22 @@ +name: PR + +on: + pull_request: + workflow_dispatch: + +permissions: + contents: read + +concurrency: + group: pr-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +jobs: + build: + uses: ./.github/workflows/_build.yml + test: + needs: build + uses: ./.github/workflows/_test.yml + integration-test: + needs: build + uses: ./.github/workflows/_integration-test.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000000..3ecf7a9b10 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,24 @@ +name: Release + +on: + push: + tags: + - '**' + +permissions: + contents: read + +jobs: + docker-image: + permissions: + contents: read + packages: write + strategy: + fail-fast: false + matrix: + service: [alarm-server, alarm-logger, save-and-restore, scan-server] + uses: ./.github/workflows/_docker-image.yml + with: + image-suffix: service-${{ matrix.service }} + context: services/${{ matrix.service }} + maven-args: ${{ matrix.service == 'scan-server' && '-Pexecutable-jar --update-snapshots package' || '--update-snapshots package' }} diff --git a/.github/workflows/report.yml b/.github/workflows/report.yml new file mode 100644 index 0000000000..a406624fb2 --- /dev/null +++ b/.github/workflows/report.yml @@ -0,0 +1,31 @@ +name: Test report + +on: + workflow_run: + workflows: + - PR + - Merge to master + types: + - completed + +permissions: + contents: read + actions: read + checks: write + pull-requests: write + +jobs: + report: + runs-on: ubuntu-latest + steps: + - name: Download test report artifacts + uses: actions/download-artifact@v7 + with: + pattern: '*test-reports' + run-id: ${{ github.event.workflow_run.id }} + github-token: ${{ github.token }} + - name: Publish test report + uses: mikepenz/action-junit-report@v6 + with: + report_paths: '**/TEST-*.xml' + commit: ${{ github.event.workflow_run.head_sha }} diff --git a/.github/workflows/save-and-restore-docker-image.yml b/.github/workflows/save-and-restore-docker-image.yml deleted file mode 100644 index 56d2a3734e..0000000000 --- a/.github/workflows/save-and-restore-docker-image.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: Save-And-Restore Docker Image CI - -on: - push: - branches: [ "master" ] - paths: services/save-and-restore/** - tags: - - '**' - -env: - REGISTRY: ghcr.io - IMAGE_NAME: ${{ github.repository }}/service-save-and-restore - -jobs: - build-and-push-image: - permissions: - contents: read - packages: write - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - java-version: '21' - distribution: 'temurin' - cache: maven - - name: Build with Maven - run: mvn --batch-mode --update-snapshots package - - name: Login to the registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Extract meta-data for Docker - id: meta - uses: docker/metadata-action@v5 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - name: Set up Docker Build - uses: docker/setup-buildx-action@v3 - - name: Build and publish the Docker image - uses: docker/build-push-action@v5 - with: - context: services/save-and-restore - push: true - platforms: linux/amd64,linux/arm64 - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha - cache-to: type=gha,mode=max diff --git a/.github/workflows/scan-server-docker-image.yml b/.github/workflows/scan-server-docker-image.yml deleted file mode 100644 index f11f8a065f..0000000000 --- a/.github/workflows/scan-server-docker-image.yml +++ /dev/null @@ -1,64 +0,0 @@ -name: Scan Server Docker Image CI - -on: - workflow_dispatch: - push: - branches: [ "master" ] - paths: services/scan-server/** - tags: - - '**' - -env: - REGISTRY: ghcr.io - IMAGE_NAME: ${{ github.repository }}/service-scan-server - -jobs: - build-server: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Maven and Java Action - uses: s4u/setup-maven-action@v1.18.0 - with: - java-version: '17' - maven-version: '3.9.6' - - name: Build - run: mvn -Pexecutable-jar --batch-mode install -DskipTests - build-and-push-image: - permissions: - contents: read - packages: write - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up JDK 17 - uses: actions/setup-java@v4 - with: - java-version: '17' - distribution: 'temurin' - cache: maven - - name: Build with Maven - run: mvn -Pexecutable-jar --batch-mode --update-snapshots package - - name: Login to the registry - uses: docker/login-action@v3 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Extract meta-data for Docker - id: meta - uses: docker/metadata-action@v5 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - name: Set up Docker Build - uses: docker/setup-buildx-action@v3 - - name: Build and publish the Docker image - uses: docker/build-push-action@v5 - with: - context: services/scan-server - push: true - platforms: linux/amd64,linux/arm64 - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha - cache-to: type=gha,mode=max diff --git a/README.md b/README.md index ebd686403c..34a4349184 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # phoebus -![GitHub Actions Status](https://github.com/ControlSystemStudio/phoebus/actions/workflows/build.yml/badge.svg) +![GitHub Actions Status](https://github.com/ControlSystemStudio/phoebus/actions/workflows/merge.yml/badge.svg) Phoebus is a framework and a collections of tools to monitor and operate large scale control systems, such as the ones in the accelerator community. Phoebus is an update of the Control System Studio toolset that removes dependencies on Eclipse RCP and SWT. From a17cee65e567ecd2436918b9c687647507ce15fe Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Wed, 17 Jun 2026 16:29:59 +0200 Subject: [PATCH 3/9] Track CI version updates via Dependabot and a versions doc Add Dependabot (github-actions ecosystem) to auto-PR action-version bumps, and update CI_VERSIONS.md Co-Authored-By: Claude Opus 4.8 --- .github/CI_VERSIONS.md | 6 ++++++ .github/dependabot.yml | 9 +++++++++ 2 files changed, 15 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/CI_VERSIONS.md b/.github/CI_VERSIONS.md index a0aee7580a..5a03756022 100644 --- a/.github/CI_VERSIONS.md +++ b/.github/CI_VERSIONS.md @@ -7,3 +7,9 @@ file is the checklist of what needs periodic review and where each pin lives. |------|---------|------------|-------| | Java (JDK) | `21` | `.github/actions/setup-java/action.yml` | Single source of truth for the CI JDK. Must match `maven.compiler.source`/`maven.compiler.target` in `pom.xml`. Review when the project adopts a new LTS. | | Elasticsearch | `8.11.2` | `.github/workflows/_integration-test.yml` and `services/save-and-restore/docker-compose.yml` | Service container for the save-and-restore integration tests. Update both files together. | + +## Automatically maintained + +GitHub Action versions (the `uses:` refs in `.github/workflows/*` and +`.github/actions/**`) are bumped by Dependabot — see `.github/dependabot.yml`. +These do **not** need manual tracking here. diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000000..7bccedcde1 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,9 @@ +version: 2 +updates: + # Auto-PR bumps for GitHub Action versions referenced in .github/workflows/* + # and in the local composite action (.github/actions/**). The JDK and + # Elasticsearch pins are not visible to Dependabot; see .github/CI_VERSIONS.md. + - package-ecosystem: github-actions + directory: / + schedule: + interval: weekly From e15a8fb0780240bd8896e60db6d6297b913cb8e1 Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Thu, 18 Jun 2026 09:59:54 +0200 Subject: [PATCH 4/9] Migrate core-ui TestFX UI tests to JUnit 5 The *UI TestFX tests still extended the JUnit 4 base org.testfx.framework.junit.ApplicationTest while their @Test methods were migrated to JUnit Jupiter (commit 9f87c086). Under the Jupiter engine the JUnit 4 lifecycle that invokes start(Stage) never runs, so the scene-graph fields are null and every test NPEs. They had been dormant since they were renamed to be skipped in CI; _test.yml's ui-tests profile re-enables them. Switch to the JUnit 5 TestFX base (org.testfx.framework.junit5.ApplicationTest) and align testfx to 4.0.18, matching app/email/ui. No other test changes. Co-Authored-By: Claude Opus 4.8 --- core/ui/pom.xml | 6 +++--- .../test/java/org/phoebus/ui/dialog/ListSelectionUI.java | 2 +- .../test/java/org/phoebus/ui/docking/DockPaneTestUI.java | 2 +- .../test/java/org/phoebus/ui/docking/SplitDockTestUI.java | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/ui/pom.xml b/core/ui/pom.xml index 6a3b49b5cd..8945a6204b 100644 --- a/core/ui/pom.xml +++ b/core/ui/pom.xml @@ -23,13 +23,13 @@ org.testfx testfx-core - 4.0.13-alpha + 4.0.18 test org.testfx - testfx-junit - 4.0.13-alpha + testfx-junit5 + 4.0.18 test diff --git a/core/ui/src/test/java/org/phoebus/ui/dialog/ListSelectionUI.java b/core/ui/src/test/java/org/phoebus/ui/dialog/ListSelectionUI.java index 687096341c..527c8778a1 100644 --- a/core/ui/src/test/java/org/phoebus/ui/dialog/ListSelectionUI.java +++ b/core/ui/src/test/java/org/phoebus/ui/dialog/ListSelectionUI.java @@ -17,7 +17,7 @@ import javafx.stage.Stage; import org.junit.jupiter.api.Test; import org.phoebus.ui.javafx.ClearingTextField; -import org.testfx.framework.junit.ApplicationTest; +import org.testfx.framework.junit5.ApplicationTest; import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeoutException; diff --git a/core/ui/src/test/java/org/phoebus/ui/docking/DockPaneTestUI.java b/core/ui/src/test/java/org/phoebus/ui/docking/DockPaneTestUI.java index b44602f5ef..f1e5aee0fb 100644 --- a/core/ui/src/test/java/org/phoebus/ui/docking/DockPaneTestUI.java +++ b/core/ui/src/test/java/org/phoebus/ui/docking/DockPaneTestUI.java @@ -6,7 +6,7 @@ import org.junit.jupiter.api.Test; import org.phoebus.security.authorization.AuthorizationService; import org.phoebus.ui.application.Messages; -import org.testfx.framework.junit.ApplicationTest; +import org.testfx.framework.junit5.ApplicationTest; import javafx.collections.ObservableList; import javafx.scene.Node; diff --git a/core/ui/src/test/java/org/phoebus/ui/docking/SplitDockTestUI.java b/core/ui/src/test/java/org/phoebus/ui/docking/SplitDockTestUI.java index de13d7a637..c9bd60fa03 100644 --- a/core/ui/src/test/java/org/phoebus/ui/docking/SplitDockTestUI.java +++ b/core/ui/src/test/java/org/phoebus/ui/docking/SplitDockTestUI.java @@ -4,7 +4,7 @@ import org.assertj.core.api.Assertions; import org.junit.jupiter.api.Test; import org.testfx.api.FxRobot; -import org.testfx.framework.junit.ApplicationTest; +import org.testfx.framework.junit5.ApplicationTest; import javafx.geometry.Bounds; import javafx.geometry.Point2D; From 01c0f9e9bebf796350fb13e65d302f6b7312941c Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Thu, 18 Jun 2026 09:59:54 +0200 Subject: [PATCH 5/9] Scope IT profile to failsafe and skip repackage; pass headless props to UI fork CI test-gate fixes for the new integration-test and ui-test jobs. integration-test: two problems kept the save-and-restore Elasticsearch-backed *IT tests from passing. - -Dspring.profiles.active=IT was forced on the whole reactor, including the surefire unit-test phase, which excluded the @Profile("!IT") mock configs and broke ~142 save-and-restore unit tests (NoSuchBeanDefinitionException: NodeDAO). Move the IT profile onto the failsafe *IT fork only via systemPropertyVariables in the module pom, drop the global -D so surefire keeps the default (mock) profile, and build just the save-and-restore module and its deps (-pl services/save-and-restore -am) so the job runs only the Elasticsearch-backed *IT tests. - The executable-jar profile's spring-boot:repackage runs at package and replaces the module's main artifact with a fat jar (classes relocated under BOOT-INF/classes/). Failsafe then ran against that repackaged artifact and couldn't resolve the flat main classes the in-process @SpringBootTest ITs field-inject (NoClassDefFoundError on ConfigurationDataRepository, ElasticsearchTreeRepository, ComparisonController). Pass -Dskip-executable-jar to deactivate the !skip-executable-jar profile so repackage is skipped and the thin jar stays as the main artifact; the executable jar is built separately by the docker-image job. ui-tests (TestFX): the headless/testfx/prism properties were only in MAVEN_OPTS, which reaches the launching Maven JVM but not the forked failsafe JVM, so ListSelectionUI's java.awt.headless skip guard never fired (its leaked modal dialog also broke DockPaneTestUI.TestContextMenu). Set them as failsafe systemPropertyVariables in the ui-tests profile so the guard works and the dock tests drive a glass robot under xvfb. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/_integration-test.yml | 2 +- pom.xml | 11 +++++++++++ services/save-and-restore/pom.xml | 15 +++++++++++++++ 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_integration-test.yml b/.github/workflows/_integration-test.yml index f40cb656a9..ceda327659 100644 --- a/.github/workflows/_integration-test.yml +++ b/.github/workflows/_integration-test.yml @@ -30,7 +30,7 @@ jobs: - name: Integration tests (Elasticsearch-backed) run: > mvn --batch-mode install -P it-tests,docker-tests - -Dspring.profiles.active=IT + -Dskip-executable-jar -pl services/save-and-restore -am - name: Upload integration test reports uses: actions/upload-artifact@v7 diff --git a/pom.xml b/pom.xml index 556891b64c..76080d18e1 100644 --- a/pom.xml +++ b/pom.xml @@ -221,6 +221,17 @@ **/*UI.java + + + true + glass + sw + diff --git a/services/save-and-restore/pom.xml b/services/save-and-restore/pom.xml index e7a59d62d0..61f8a0aca1 100644 --- a/services/save-and-restore/pom.xml +++ b/services/save-and-restore/pom.xml @@ -196,6 +196,21 @@ true + + + + maven-failsafe-plugin + + + IT + + + + From f3b477de0c868cffaf68f6f739c6fbbe473b084e Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Thu, 18 Jun 2026 11:17:10 +0200 Subject: [PATCH 6/9] Split UI tests into their own CI job; run all unit tests with --fail-at-end Previously a single _test.yml job ran unit (surefire) and TestFX UI (failsafe *UI) tests together, and the fail-fast reactor skipped every later module once one module's tests failed. - Add _unit-test.yml: surefire tests across the reactor with --fail-at-end, so every independent module is tested even when another fails. - Add _ui-test.yml: the *UI TestFX tests only, under xvfb. The ui-tests profile now skips surefire (plugin-config level, so failsafe still runs), making -P ui-tests mean 'UI tests only'. - Rewire pr.yml and merge.yml to call both reusable workflows; remove _test.yml. - report.yml already globs *test-reports, so it picks up the unit-test-reports, ui-test-reports and integration-test-reports artifacts. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/{_test.yml => _ui-test.yml} | 12 ++++---- .github/workflows/_unit-test.yml | 28 +++++++++++++++++++ .github/workflows/merge.yml | 6 ++-- .github/workflows/pr.yml | 7 +++-- pom.xml | 14 ++++++++-- 5 files changed, 54 insertions(+), 13 deletions(-) rename .github/workflows/{_test.yml => _ui-test.yml} (75%) create mode 100644 .github/workflows/_unit-test.yml diff --git a/.github/workflows/_test.yml b/.github/workflows/_ui-test.yml similarity index 75% rename from .github/workflows/_test.yml rename to .github/workflows/_ui-test.yml index dbd297fb0d..70126288ee 100644 --- a/.github/workflows/_test.yml +++ b/.github/workflows/_ui-test.yml @@ -1,4 +1,4 @@ -name: Test +name: UI test on: workflow_call: @@ -7,7 +7,7 @@ permissions: contents: read jobs: - test: + ui-test: runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 @@ -16,7 +16,7 @@ jobs: - name: Test run: > xvfb-run -a - mvn --batch-mode verify -P ui-tests + mvn --batch-mode --fail-at-end verify -P ui-tests env: MAVEN_OPTS: >- -Djava.awt.headless=true -Dtestfx.robot=glass -Dtestfx.headless=true @@ -25,8 +25,6 @@ jobs: uses: actions/upload-artifact@v7 if: always() with: - name: test-reports - path: | - **/target/surefire-reports/** - **/target/failsafe-reports/** + name: ui-test-reports + path: '**/target/failsafe-reports/**' if-no-files-found: ignore diff --git a/.github/workflows/_unit-test.yml b/.github/workflows/_unit-test.yml new file mode 100644 index 0000000000..e2ec88c6e7 --- /dev/null +++ b/.github/workflows/_unit-test.yml @@ -0,0 +1,28 @@ +name: Unit test + +on: + workflow_call: + +permissions: + contents: read + +jobs: + unit-test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Set up Java + uses: ./.github/actions/setup-java + - name: Unit test + run: > + xvfb-run -a + mvn --batch-mode --fail-at-end verify + env: + MAVEN_OPTS: -Djava.awt.headless=true -Dprism.order=sw -Dprism.text=t2k + - name: Upload test reports + uses: actions/upload-artifact@v7 + if: always() + with: + name: unit-test-reports + path: '**/target/surefire-reports/**' + if-no-files-found: ignore diff --git a/.github/workflows/merge.yml b/.github/workflows/merge.yml index e0281e87f1..bfc155d770 100644 --- a/.github/workflows/merge.yml +++ b/.github/workflows/merge.yml @@ -18,8 +18,10 @@ jobs: with: os: ${{ matrix.os }} upload-artifacts: true - test: - uses: ./.github/workflows/_test.yml + unit-test: + uses: ./.github/workflows/_unit-test.yml + ui-test: + uses: ./.github/workflows/_ui-test.yml integration-test: uses: ./.github/workflows/_integration-test.yml diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 9e44092dac..1f7b57f2a7 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -14,9 +14,12 @@ concurrency: jobs: build: uses: ./.github/workflows/_build.yml - test: + unit-test: needs: build - uses: ./.github/workflows/_test.yml + uses: ./.github/workflows/_unit-test.yml + ui-test: + needs: build + uses: ./.github/workflows/_ui-test.yml integration-test: needs: build uses: ./.github/workflows/_integration-test.yml diff --git a/pom.xml b/pom.xml index 76080d18e1..f6b4cd854e 100644 --- a/pom.xml +++ b/pom.xml @@ -206,8 +206,10 @@ false - + ui-tests @@ -215,6 +217,14 @@ + + + maven-surefire-plugin + + true + + maven-failsafe-plugin From 66ccd48a5da3ff0dd0c5bb613f3cc5b5895e4c85 Mon Sep 17 00:00:00 2001 From: Sky Brewer Date: Thu, 18 Jun 2026 14:24:34 +0200 Subject: [PATCH 7/9] Isolate JavaFX-dependent unit tests into the UI test job Some unit tests (e.g. those using javafx.scene.paint.Color) require the JavaFX toolkit to be initialized, which fails in a pure headless environment without xvfb or specific prism properties. - Rename 11 unit tests that import javafx.* to *FXTest.java. - Exclude **/*FXTest.java from the default surefire execution in pom.xml. - Include **/*FXTest.java in the ui-tests and all-tests profiles via failsafe. - Remove xvfb-run and graphics properties from _unit-test.yml, making it a truly headless job. - These *FXTest tests will now run in the _ui-test.yml job under xvfb. Co-Authored-By: Gemini-Cli <218195315+gemini-cli@users.noreply.github.com> --- .github/workflows/_unit-test.yml | 6 +----- ...nceTest.java => AlarmTableUpdatePerformanceFXTest.java} | 2 +- .../{XMLPersistenceTest.java => XMLPersistenceFXTest.java} | 2 +- ...reeRootNodeTest.java => FormulaTreeRootNodeFXTest.java} | 2 +- .../javafx/{JFXUtilTest.java => JFXUtilFXTest.java} | 2 +- .../javafx/{SVGHelperTest.java => SVGHelperFXTest.java} | 2 +- .../{GraphicsUtilsTest.java => GraphicsUtilsFXTest.java} | 2 +- .../{DragNDropUtilTest.java => DragNDropUtilFXTest.java} | 2 +- ...ctoryTest.java => DataBrowserAdapterFactoryFXTest.java} | 2 +- .../javafx/{ImageCacheTest.java => ImageCacheFXTest.java} | 2 +- .../ui/javafx/{JFXUtilTest.java => JFXUtilFXTest.java} | 2 +- .../{SVGTranscoderTest.java => SVGTranscoderFXTest.java} | 2 +- pom.xml | 7 +++++++ 13 files changed, 19 insertions(+), 16 deletions(-) rename app/alarm/ui/src/test/java/org/phoebus/applications/alarm/{AlarmTableUpdatePerformanceTest.java => AlarmTableUpdatePerformanceFXTest.java} (99%) rename app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/{XMLPersistenceTest.java => XMLPersistenceFXTest.java} (99%) rename app/diag/src/test/java/org/phoebus/app/diag/ui/{FormulaTreeRootNodeTest.java => FormulaTreeRootNodeFXTest.java} (98%) rename app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/{JFXUtilTest.java => JFXUtilFXTest.java} (99%) rename app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/{SVGHelperTest.java => SVGHelperFXTest.java} (99%) rename app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/{GraphicsUtilsTest.java => GraphicsUtilsFXTest.java} (98%) rename app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/{DragNDropUtilTest.java => DragNDropUtilFXTest.java} (99%) rename app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/{DataBrowserAdapterFactoryTest.java => DataBrowserAdapterFactoryFXTest.java} (98%) rename core/ui/src/test/java/org/phoebus/ui/javafx/{ImageCacheTest.java => ImageCacheFXTest.java} (98%) rename core/ui/src/test/java/org/phoebus/ui/javafx/{JFXUtilTest.java => JFXUtilFXTest.java} (97%) rename core/ui/src/test/java/org/phoebus/ui/javafx/svg/{SVGTranscoderTest.java => SVGTranscoderFXTest.java} (98%) diff --git a/.github/workflows/_unit-test.yml b/.github/workflows/_unit-test.yml index e2ec88c6e7..39dc3d2809 100644 --- a/.github/workflows/_unit-test.yml +++ b/.github/workflows/_unit-test.yml @@ -14,11 +14,7 @@ jobs: - name: Set up Java uses: ./.github/actions/setup-java - name: Unit test - run: > - xvfb-run -a - mvn --batch-mode --fail-at-end verify - env: - MAVEN_OPTS: -Djava.awt.headless=true -Dprism.order=sw -Dprism.text=t2k + run: mvn --batch-mode --fail-at-end verify - name: Upload test reports uses: actions/upload-artifact@v7 if: always() diff --git a/app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceTest.java b/app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceFXTest.java similarity index 99% rename from app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceTest.java rename to app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceFXTest.java index 7728c5ca04..304ae561ec 100644 --- a/app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceTest.java +++ b/app/alarm/ui/src/test/java/org/phoebus/applications/alarm/AlarmTableUpdatePerformanceFXTest.java @@ -47,7 +47,7 @@ * @see Issue #3504 */ @SuppressWarnings("nls") -class AlarmTableUpdatePerformanceTest +class AlarmTableUpdatePerformanceFXTest { private static final int N = 150; // Large enough to expose O(N^2) but fast to run diff --git a/app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceTest.java b/app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceFXTest.java similarity index 99% rename from app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceTest.java rename to app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceFXTest.java index 429c19eb5a..10733c18ba 100644 --- a/app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceTest.java +++ b/app/databrowser/src/test/java/org/csstudio/trends/databrowser3/persistence/XMLPersistenceFXTest.java @@ -36,7 +36,7 @@ *

Tests are organized by feature area using nested test classes. */ @DisplayName("XMLPersistence") -class XMLPersistenceTest { +class XMLPersistenceFXTest { // --------------------------------------------------------------------------- // Constants diff --git a/app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeTest.java b/app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeFXTest.java similarity index 98% rename from app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeTest.java rename to app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeFXTest.java index 1612440d43..765c0eb057 100644 --- a/app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeTest.java +++ b/app/diag/src/test/java/org/phoebus/app/diag/ui/FormulaTreeRootNodeFXTest.java @@ -13,7 +13,7 @@ import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertTrue; -public class FormulaTreeRootNodeTest { +public class FormulaTreeRootNodeFXTest { public FormulaFunction createFormula(String name, String description, String category) { return new FormulaFunction() { diff --git a/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilTest.java b/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilFXTest.java similarity index 99% rename from app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilTest.java rename to app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilFXTest.java index 2167b2d6d1..80df597697 100644 --- a/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilTest.java +++ b/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilFXTest.java @@ -21,7 +21,7 @@ * @author Kay Kasemir */ @SuppressWarnings("nls") -public class JFXUtilTest +public class JFXUtilFXTest { @Test diff --git a/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperTest.java b/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperFXTest.java similarity index 99% rename from app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperTest.java rename to app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperFXTest.java index 970a61b16c..fc63450bf1 100644 --- a/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperTest.java +++ b/app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/SVGHelperFXTest.java @@ -29,7 +29,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; -public class SVGHelperTest { +public class SVGHelperFXTest { /** * Verifies that the SVG file can be loaded and that the created {@link Image} has diff --git a/app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsTest.java b/app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsFXTest.java similarity index 98% rename from app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsTest.java rename to app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsFXTest.java index e1954d6ed9..6f2702e6b2 100644 --- a/app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsTest.java +++ b/app/rtplot/src/test/java/org/csstudio/javafx/rtplot/util/GraphicsUtilsFXTest.java @@ -24,7 +24,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; -public class GraphicsUtilsTest { +public class GraphicsUtilsFXTest { @Test public void convertColor1(){ diff --git a/app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilTest.java b/app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilFXTest.java similarity index 99% rename from app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilTest.java rename to app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilFXTest.java index 458d0b19e3..0da08d5982 100644 --- a/app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilTest.java +++ b/app/save-and-restore/app/src/test/java/org/phoebus/applications/saveandrestore/ui/DragNDropUtilFXTest.java @@ -30,7 +30,7 @@ import static org.junit.jupiter.api.Assertions.*; -public class DragNDropUtilTest { +public class DragNDropUtilFXTest { private final Node folderTargetNode = Node.builder().uniqueId(UUID.randomUUID().toString()).nodeType(NodeType.FOLDER).build(); private final Node compositeSnapshotTargetNode = Node.builder().uniqueId(UUID.randomUUID().toString()).nodeType(NodeType.COMPOSITE_SNAPSHOT).build(); diff --git a/app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryTest.java b/app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryFXTest.java similarity index 98% rename from app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryTest.java rename to app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryFXTest.java index 5a205bad5c..2812e8f3ff 100644 --- a/app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryTest.java +++ b/app/trends/rich-adapters/src/test/java/org/phoebus/apps/trends/rich/adapters/DataBrowserAdapterFactoryFXTest.java @@ -36,7 +36,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.Mockito.when; -public class DataBrowserAdapterFactoryTest { +public class DataBrowserAdapterFactoryFXTest { @Test public void testGetAdaptableObject(){ diff --git a/core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheTest.java b/core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheFXTest.java similarity index 98% rename from core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheTest.java rename to core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheFXTest.java index 09b96a873a..a6d52a32f0 100644 --- a/core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheTest.java +++ b/core/ui/src/test/java/org/phoebus/ui/javafx/ImageCacheFXTest.java @@ -25,7 +25,7 @@ * @author Kay Kasemir */ @SuppressWarnings("nls") -public class ImageCacheTest extends Application +public class ImageCacheFXTest extends Application { @Override public void start(final Stage stage) throws Exception diff --git a/core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilTest.java b/core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilFXTest.java similarity index 97% rename from core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilTest.java rename to core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilFXTest.java index 9a2aa03187..51e8829281 100644 --- a/core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilTest.java +++ b/core/ui/src/test/java/org/phoebus/ui/javafx/JFXUtilFXTest.java @@ -23,7 +23,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; -public class JFXUtilTest { +public class JFXUtilFXTest { @Test public void testWebRGB(){ diff --git a/core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderTest.java b/core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderFXTest.java similarity index 98% rename from core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderTest.java rename to core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderFXTest.java index 18648101a3..2910b320ec 100644 --- a/core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderTest.java +++ b/core/ui/src/test/java/org/phoebus/ui/javafx/svg/SVGTranscoderFXTest.java @@ -27,7 +27,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; -public class SVGTranscoderTest { +public class SVGTranscoderFXTest { /** * Verifies that the SVG file can be loaded and that the created {@link Image} has diff --git a/pom.xml b/pom.xml index f6b4cd854e..8a3ecd75a5 100644 --- a/pom.xml +++ b/pom.xml @@ -123,6 +123,11 @@ org.apache.maven.plugins maven-surefire-plugin 3.0.0-M7 + + + **/*FXTest.java + + org.apache.maven.plugins @@ -230,6 +235,7 @@ **/*UI.java + **/*FXTest.java