GitHub Actions: Use software OpenGL driver for tests on Windows

Since some tests are failing due to missing OpenGL context, I assume
the GitHub Actions Windows runners do not have OpenGL drivers.

Change-Id: I7951f0906d37bc1d513e77540fdd379a71cbed60
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Cristian Adam
2022-07-08 21:53:35 +02:00
parent 397ba273cb
commit 9c09ade2ed

View File

@@ -129,6 +129,18 @@ jobs:
endif()
endif()
if ("${{ runner.os }}" STREQUAL "Windows")
file(MAKE_DIRECTORY build/build/bin)
foreach(retry RANGE 10)
file(DOWNLOAD "https://download.qt.io/development_releases/prebuilt/llvmpipe/windows/opengl32sw-64.7z" ./opengl32sw-64.7z SHOW_PROGRESS)
file(SIZE ./opengl32sw-64.7z fileSize)
if (fileSize GREATER 0)
break()
endif()
endforeach()
execute_process(COMMAND ${CMAKE_COMMAND} -E tar xvf ../../../opengl32sw-64.7z WORKING_DIRECTORY build/build/bin)
endif()
if (NOT "x${{ matrix.config.toolchain }}" STREQUAL "x")
foreach(retry RANGE 10)
file(DOWNLOAD "${{ matrix.config.toolchain }}" ./toolchain.7z SHOW_PROGRESS)
@@ -594,6 +606,9 @@ jobs:
if ("${{ runner.os }}" STREQUAL "Linux")
set(ENV{QT_QPA_PLATFORM} "offscreen")
elseif ("${{ runner.os }}" STREQUAL "Windows")
set(ENV{QT_OPENGL} "software")
set(ENV{QT_ASSUME_STDERR_HAS_CONSOLE} "1")
endif()
execute_process(