Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix maui integration test #2948

Merged
merged 5 commits into from
Dec 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
- release/*
pull_request:
paths-ignore:
- '**.md'
- "**.md"

jobs:
build-sentry-native:
Expand Down Expand Up @@ -104,7 +104,7 @@ jobs:

# Only switch to newer xcode after building the Cocoa SDK so that it can keep IPHONEOS_DEPLOYMENT_TARGET=11.0
- run: sudo xcode-select -s /Applications/Xcode_15.0.1.app
if: startsWith(matrix.os, 'macos')
if: runner.os == 'macOS'

- name: Restore .NET Dependencies
run: dotnet restore Sentry-CI-Build-${{ runner.os }}.slnf --nologo
Expand Down Expand Up @@ -141,12 +141,12 @@ jobs:
integration-test:
needs: build
name: Integration test (${{ matrix.os }})
runs-on: ${{ matrix.os }}-latest
runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
os: [ubuntu, windows, macos]
os: [ubuntu-latest, windows-latest, macos-13]

steps:
- uses: actions/checkout@v4
Expand All @@ -169,11 +169,12 @@ jobs:
sudo apt update
sudo apt install libcurl4-openssl-dev

- run: sudo xcode-select -s /Applications/Xcode_15.0.1.app
if: runner.os == 'macOS'

- uses: actions/setup-dotnet@v3
with:
dotnet-version: |
7.0.x
8.0.x
dotnet-version: 8.0.x

- run: dotnet workload install android maui-android

Expand Down
11 changes: 5 additions & 6 deletions integration-test/cli.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,9 @@ Describe 'Console apps (<framework>) - native AOT publish' -ForEach @(
}
}

# TODO creating a sample app with `dotnet new` currently fails in CI on all platforms with:
# 'error: NU1100: Unable to resolve 'Microsoft.Extensions.Http (>= 6.0.0)' for 'net7.0-android33.0'. PackageSourceMapping is enabled, the following source(s) were not considered: integration-test.'
# Tracking issue: https://github.com/getsentry/sentry-dotnet/issues/2809
Describe 'MAUI' -ForEach @(
@{ framework = "net7.0" }
) -Skip:$true {
@{ framework = "net8.0" }
) {
BeforeAll {
RegisterLocalPackage 'Sentry.Android.AssemblyReader'
RegisterLocalPackage 'Sentry.Bindings.Android'
Expand Down Expand Up @@ -155,7 +152,7 @@ Describe 'MAUI' -ForEach @(
'libxamarin-app.so',
'maui-app.pdb'
)
$result.ScriptOutput | Should -AnyElementMatch 'Found 1 debug information file \(1 with embedded sources\)'
$result.ScriptOutput | Should -AnyElementMatch 'Found 17 debug information files \(1 with embedded sources\)'
$result.ScriptOutput | Should -AnyElementMatch 'Uploaded a total of 1 new mapping files'
}

Expand All @@ -165,7 +162,9 @@ Describe 'MAUI' -ForEach @(
'libmono-component-debugger.dylib',
'libmono-component-diagnostics_tracing.dylib',
'libmono-component-hot_reload.dylib',
'libmono-component-marshal-ilgen.dylib',
'libmonosgen-2.0.dylib',
'libSystem.Globalization.Native.dylib',
'libSystem.IO.Compression.Native.dylib',
'libSystem.Native.dylib',
'libSystem.Net.Security.Native.dylib',
Expand Down
Loading