ci: validate macOS managed behavior on Ubuntu and stabilize shutdown
PR and Push Build/Test / build-and-test (pull_request) Blocked by required conditions
PR and Push Build/Test / portable-build-and-test (pull_request) Blocked by required conditions

This commit is contained in:
dh
2026-10-03 11:30:29 +02:00
parent bd35ebc4c8
commit 1164c26846
10 changed files with 201 additions and 72 deletions
+28 -20
View File
@@ -48,13 +48,13 @@ jobs:
echo "WINE_BIN=${WINE_BIN}" >> "${GITHUB_ENV}"
"${WINE_BIN}" --version
- name: Restore (Windows target)
- name: Restore (portable tests for Windows/Wine)
run: |
dotnet restore MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-p:EnableWindowsTargeting=true \
-r win-x64
- name: Build (Windows target)
- name: Build (portable tests for Windows/Wine)
run: |
dotnet build MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-c Release \
@@ -77,37 +77,47 @@ jobs:
echo "WIN_DOTNET_DIR=${WIN_DOTNET_DIR}" >> "${GITHUB_ENV}"
"${WINE_BIN}" "${WIN_DOTNET_DIR}/dotnet.exe" --info
- name: Build Windows desktop target via Wine
run: |
rm -f MeetingAssistant/bin/Release/net10.0-windows10.0.19041.0/win-x64/MeetingAssistant.dll
"${WINE_BIN}" "${WIN_DOTNET_DIR}/dotnet.exe" build MeetingAssistant/MeetingAssistant.csproj \
-c Release \
-f net10.0-windows10.0.19041.0 \
-r win-x64 \
-p:EnableWindowsTargeting=true \
--nologo
test -s MeetingAssistant/bin/Release/net10.0-windows10.0.19041.0/win-x64/MeetingAssistant.dll
- name: Run tests via Wine (Windows dotnet host)
run: |
rm -f artifacts/tests/wine.trx
"${WINE_BIN}" "${WIN_DOTNET_DIR}/dotnet.exe" test MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-c Release \
-r win-x64 \
--no-build \
--logger "trx;LogFileName=wine.trx" \
--results-directory artifacts/tests \
--nologo
test -s artifacts/tests/wine.trx
- name: Show test output folder on failure
if: failure()
run: |
find artifacts/tests -type f -print || true
find MeetingAssistant.Tests -type d -name TestResults -print || true
find MeetingAssistant.Tests -type f -path "*/TestResults/*" -maxdepth 5 -print || true
macos-build-and-test:
runs-on: macos
portable-build-and-test:
runs-on: ubuntu-latest
env:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "1"
DOTNET_NOLOGO: "1"
TZ: "Europe/Berlin"
steps:
- name: Checkout repository
uses: actions/checkout@v7
- name: Verify native macOS runner
run: |
if [ "$(uname -s)" != "Darwin" ]; then
echo "The macos job requires a native Gitea runner registered with the macos:host label."
exit 1
fi
- name: Setup .NET
uses: actions/setup-dotnet@v6
with:
@@ -118,7 +128,7 @@ jobs:
dotnet restore MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-p:EnableWindowsTargeting=true
- name: Build (portable target and macOS helpers)
- name: Build (portable target including macOS managed adapters)
run: |
dotnet build MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-c Release \
@@ -127,24 +137,22 @@ jobs:
-p:EnableWindowsTargeting=true \
--nologo
- name: Verify macOS native helpers
run: |
test -x MeetingAssistant/bin/Release/net10.0/Native/MeetingAssistantAudioCapture.app/Contents/MacOS/macos-meeting-audio-capture
test -x MeetingAssistant/bin/Release/net10.0/Native/macos-desktop-controls
test -x MeetingAssistant/bin/Release/net10.0/Native/macos-meeting-integrations
test -x MeetingAssistant/bin/Release/net10.0/Native/macos-meeting-assistant-launcher
- name: Run tests on macOS
- name: Run portable and macOS managed behavior tests on Ubuntu
run: |
rm -f artifacts/tests/portable.trx
dotnet test MeetingAssistant.Tests/MeetingAssistant.Tests.csproj \
-c Release \
-f net10.0 \
--no-build \
-p:EnableWindowsTargeting=true \
--logger "trx;LogFileName=portable.trx" \
--results-directory artifacts/tests \
--nologo
test -s artifacts/tests/portable.trx
- name: Show test output folder on failure
if: failure()
run: |
find artifacts/tests -type f -print || true
find MeetingAssistant.Tests -type d -name TestResults -print || true
find MeetingAssistant.Tests -type f -path "*/TestResults/*" -maxdepth 5 -print || true