Skip to content

Commit

Permalink
GA: run hdGatling graphical tests
Browse files Browse the repository at this point in the history
  • Loading branch information
pablode committed Dec 2, 2024
1 parent ca27332 commit 3909465
Show file tree
Hide file tree
Showing 5 changed files with 90 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-houdini20.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
build-config: Release
usd-download-url: ${{ matrix.usd-download-url }}
usd-install-path: ${{ matrix.usd-install-path }}
upload-archive: true
upload-install-artifacts: true
archive-name: build-Release-${{ github.sha }}
archive-file-name: ${{ matrix.archive-file-name }}
mdl-sdk-cache-key: ${{ inputs.mdl-sdk-cache-key-prefix }}_${{ matrix.image }}
Expand Down
27 changes: 22 additions & 5 deletions .github/workflows/build-usd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,19 @@ on:
required: false
type: string
default: "MDL-SDK"
upload-archives:
upload-install-artifacts:
description: "Whether build results should be uploaded or not"
required: false
type: boolean
default: false
run-graphical-tests:
required: false
type: boolean
default: false
upload-test-artifacts:
required: false
type: boolean
default: false

jobs:
build:
Expand All @@ -38,34 +46,43 @@ jobs:
image: ubuntu-20.04
usd-download-url: "https://github.com/pablode/USD/releases/download/v${{ inputs.usd-version }}-ci-release/USD${{ inputs.usd-version }}_Linux_x64.tar.gz"
usd-install-path: "/home/runner/work/USD/USD/INSTALL"
upload-archive: ${{ inputs.upload-archives }}
upload-install-artifacts: ${{ inputs.upload-install-artifacts }}
archive-file-name: "gatling_USD${{ inputs.usd-version }}_Linux_x64.tar.gz"
cmake-params:
run-graphical-tests: ${{ inputs.run-graphical-tests }}
executable-suffix:

- name: Ubuntu / clang
image: ubuntu-20.04
usd-download-url: "https://github.com/pablode/USD/releases/download/v${{ inputs.usd-version }}-ci-release/USD${{ inputs.usd-version }}_Linux_x64.tar.gz"
usd-install-path: "/home/runner/work/USD/USD/INSTALL"
# Don't upload clang build results -- we already have GCC's
upload-archive: false
upload-install-artifacts: false
cmake-params: -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++
run-graphical-tests: false
executable-suffix:

- name: Windows / MSVC
image: windows-2019
usd-download-url: "https://github.com/pablode/USD/releases/download/v${{ inputs.usd-version }}-ci-release/USD${{ inputs.usd-version }}_Windows_x64.tar.gz"
usd-install-path: "C:/INSTALL"
upload-archive: ${{ inputs.upload-archives }}
upload-install-artifacts: ${{ inputs.upload-install-artifacts }}
archive-file-name: "gatling_USD${{ inputs.usd-version }}_Windows_x64.tar.gz"
cmake-params: -G"Visual Studio 16 2019" -Ax64
run-graphical-tests: false
executable-suffix: '.exe'

uses: ./.github/workflows/build.yml
with:
image: ${{ matrix.image }}
build-config: ${{ inputs.build-config }}
usd-download-url: ${{ matrix.usd-download-url }}
usd-install-path: ${{ matrix.usd-install-path }}
upload-archive: ${{ matrix.upload-archive }}
upload-install-artifacts: ${{ matrix.upload-install-artifacts }}
archive-name: build-${{ inputs.build-config }}-${{ github.sha }}
archive-file-name: ${{ matrix.archive-file-name }}
mdl-sdk-cache-key: ${{ inputs.mdl-sdk-cache-key-prefix }}_${{ matrix.image }}
cmake-params: ${{ matrix.cmake-params }}
run-graphical-tests: ${{ matrix.run-graphical-tests }}
upload-test-artifacts: ${{ inputs.upload-test-artifacts }}
executable-suffix: ${{ matrix.executable-suffix }}
63 changes: 54 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
usd-install-path:
required: true
type: string
upload-archive:
upload-install-artifacts:
required: false
type: boolean
default: false
Expand All @@ -36,6 +36,18 @@ on:
required: false
type: boolean
default: false
run-graphical-tests:
required: false
type: boolean
default: false
upload-test-artifacts:
required: false
type: boolean
default: false
executable-suffix:
required: false
type: string
default: ''

defaults:
run:
Expand All @@ -54,12 +66,38 @@ jobs:
uses: actions/checkout@v4
with:
submodules: recursive
lfs: true

- name: Install libgl1 package
if: runner.os == 'Linux'
# There seems to be a transitive dependency on libGL (perhaps by hgi)
run: sudo apt-get update && sudo apt-get install libgl1-mesa-dev

- name: Install Mesa & Vulkan packages
if: ${{ runner.os == 'Linux' && inputs.run-graphical-tests }}
run: |
sudo add-apt-repository ppa:kisak/kisak-mesa
sudo apt update
sudo apt upgrade
sudo apt-get install mesa-utils xvfb qt5-default libgl1-mesa-dev libvulkan-dev vulkan-tools mesa-vulkan-drivers
- name: Set up graphical environment variables
if: ${{ runner.os == 'Linux' && inputs.run-graphical-tests }}
run: |
echo "LD_LIBRARY_PATH=${{ inputs.usd-install-path }}/lib" >> $GITHUB_ENV
echo "DISPLAY=:1" >> $GITHUB_ENV
echo "LIBGL_ALWAYS_SOFTWARE=1" >> $GITHUB_ENV
echo "GALLIUM_DRIVER=llvmpipe" >> $GITHUB_ENV
- name: Start virtual framebuffer
if: ${{ runner.os == 'Linux' && inputs.run-graphical-tests }}
run: |
Xvfb :1 -screen 0 1280x960x24 &
- name: Test vulkaninfo
if: ${{ runner.os == 'Linux' && inputs.run-graphical-tests }}
run: vulkaninfo

- name: Fetch USD binaries
run: curl ${{ inputs.usd-download-url }} -L -v -o USD.tar.gz

Expand Down Expand Up @@ -109,13 +147,12 @@ jobs:

- name: Run imgio_test
working-directory: BUILD
if: runner.os != 'Windows'
run: ./bin/imgio_test
run: ./bin/imgio_test${{ inputs.executable-suffix }}

- name: Run imgio_test
- name: Run hdGatling_test
working-directory: BUILD
if: runner.os == 'Windows'
run: ./bin/imgio_test.exe
if: inputs.run-graphical-tests
run: ./bin/hdGatling_test${{ inputs.executable-suffix }}

- name: Install gatling
working-directory: BUILD
Expand All @@ -134,13 +171,21 @@ jobs:
mv hdGatling dso/usd_plugins
mv hdGatling* dso/usd
- name: Create archive
if: inputs.upload-archive
- name: Upload test artifacts
if: ${{ inputs.run-graphical-tests && inputs.upload-test-artifacts && failure() }}
uses: actions/upload-artifact@v3
with:
name: test-artifacts
path: TEST/*
retention-days: 7

- name: Create install artifacts
if: inputs.upload-install-artifacts
working-directory: INSTALL
run: tar -zcvf ${{ inputs.archive-file-name }} *

- name: Upload archive
if: inputs.upload-archive
if: inputs.upload-install-artifacts
uses: actions/upload-artifact@v3
with:
name: ${{ inputs.archive-name }}
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/deploy-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ jobs:
with:
usd-version: 24.11
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
upload-archives: true
upload-install-artifacts: true
run-graphical-tests: true

build-usd2408:
name: Build gatling for USD v24.08
Expand All @@ -26,7 +27,8 @@ jobs:
with:
usd-version: 24.08
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
upload-archives: true
upload-install-artifacts: true
run-graphical-tests: true

build-usd2405:
name: Build gatling for USD v24.05
Expand All @@ -35,7 +37,7 @@ jobs:
with:
usd-version: 24.05
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
upload-archives: true
upload-install-artifacts: true

build-usd2403:
name: Build gatling for USD v24.03
Expand All @@ -44,7 +46,7 @@ jobs:
with:
usd-version: 24.03
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
upload-archives: true
upload-install-artifacts: true

build-houdini20:
name: Build gatling for Houdini 20.0
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Validation Build

on:
push:
branches:
- 'master'
- 'dev'
#branches:
# - 'master'
# - 'dev'
paths-ignore:
- '**.md'
- '**.glsl'
Expand All @@ -23,6 +23,8 @@ jobs:
with:
usd-version: 24.11
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
run-graphical-tests: true
upload-test-artifacts: true

build-2408:
name: Build gatling for USD v24.08 (Release)
Expand All @@ -31,6 +33,8 @@ jobs:
with:
usd-version: 24.08
mdl-sdk-cache-key-prefix: ${{ vars.MDL_SDK_CACHE_KEY_PREFIX }}
run-graphical-tests: true
upload-test-artifacts: true

build-2405:
name: Build gatling for USD v24.05 (Release)
Expand Down

0 comments on commit 3909465

Please sign in to comment.