From: Mike McLaughlin Date: Wed, 28 Jul 2021 21:17:27 +0000 (-0700) Subject: Update alpine image that includes lldb python support and enable tests on 6.0 (#2460) X-Git-Tag: submit/tizen/20220302.040122~21^2^2~191 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9dc72da9618bbb8c57b902d5e3721ebdfa47b681;p=platform%2Fcore%2Fdotnet%2Fdiagnostics.git Update alpine image that includes lldb python support and enable tests on 6.0 (#2460) * Update alpine image that includes lldb python support * Enable lldb and dump tests on Alpine * Don't run the bpmd portions of the tests on Alpine * Add requiresCapPtraceContainer:true to Alpine legs --- diff --git a/diagnostics.yml b/diagnostics.yml index 5ff5383ad..0ffba53fd 100644 --- a/diagnostics.yml +++ b/diagnostics.yml @@ -142,8 +142,9 @@ stages: parameters: name: Alpine3_13 osGroup: Linux - dockerImage: mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.13-WithNode-20210720123506-ddfc481 + dockerImage: mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.13-WithNode-20210728123842-ddfc481 artifactsTargetPath: bin/Linux-musl.x64.Release + requiresCapPtraceContainer: true strategy: matrix: Build_Release: diff --git a/src/SOS/SOS.UnitTests/SOS.cs b/src/SOS/SOS.UnitTests/SOS.cs index e1f6ec5fd..1f3ad1689 100644 --- a/src/SOS/SOS.UnitTests/SOS.cs +++ b/src/SOS/SOS.UnitTests/SOS.cs @@ -41,9 +41,8 @@ public class SOS { information.OutputHelper = Output; - // TODO: enable when the Alpine images (we are currently using 3.13) have the py3-lldb package installed. // TODO: enable either when bpmd is fixed on Alpine or the bpmd tests are ifdef'ed out of the scripts for Alpine - if (testLive && !SOSRunner.IsAlpine()) + if (testLive) { // Live using (SOSRunner runner = await SOSRunner.StartDebugger(information, SOSRunner.DebuggerAction.Live)) @@ -52,12 +51,10 @@ public class SOS } } - // TODO: enable for 6.0 when PR https://github.com/dotnet/runtime/pull/56272 is merged/released - if (testDump && !SOSRunner.IsAlpine()) + if (testDump) { - // Create and test dumps on OSX only if the runtime is 6.0 or greater - // TODO: reenable for 5.0 when the MacOS createdump fixes make it into a service release (https://github.com/dotnet/diagnostics/issues/1749) - if (OS.Kind != OSKind.OSX || information.TestConfiguration.RuntimeFrameworkVersionMajor > 5) + // Create and test dumps on OSX or Alpine only if the runtime is 6.0 or greater + if (!(OS.Kind == OSKind.OSX || SOSRunner.IsAlpine()) || information.TestConfiguration.RuntimeFrameworkVersionMajor > 5) { // Generate a crash dump. if (information.TestConfiguration.DebuggeeDumpOutputRootDir() != null) diff --git a/src/SOS/SOS.UnitTests/Scripts/NestedExceptionTest.script b/src/SOS/SOS.UnitTests/Scripts/NestedExceptionTest.script index a08bb14a8..5414b4a00 100644 --- a/src/SOS/SOS.UnitTests/Scripts/NestedExceptionTest.script +++ b/src/SOS/SOS.UnitTests/Scripts/NestedExceptionTest.script @@ -9,6 +9,8 @@ LOADSOS # Verify that bpmd works IFDEF:LIVE !IFDEF:MAJOR_RUNTIME_VERSION_1 +# Issue: https://github.com/dotnet/diagnostics/issues/2459 +!IFDEF:ALPINE IFDEF:DESKTOP SOSCOMMAND:bpmd NestedExceptionTest.exe NestedExceptionTest.Program.Main @@ -27,6 +29,7 @@ SOSCOMMAND:ClrStack VERIFY:\s+\s+\s+NestedExceptionTest\.Program\.Main(\(.*\))?\s* VERIFY:\[.*[\\|/]Debuggees[\\|/](dotnet.+[\\|/])?[Nn]ested[Ee]xception[Tt]est[\\|/][Nn]ested[Ee]xception[Tt]est\.cs @ 8\s*\]\s* +ENDIF:ALPINE ENDIF:MAJOR_RUNTIME_VERSION_1 ENDIF:LIVE diff --git a/src/SOS/SOS.UnitTests/Scripts/OtherCommands.script b/src/SOS/SOS.UnitTests/Scripts/OtherCommands.script index 3bade4425..91fe0db65 100644 --- a/src/SOS/SOS.UnitTests/Scripts/OtherCommands.script +++ b/src/SOS/SOS.UnitTests/Scripts/OtherCommands.script @@ -7,6 +7,8 @@ LOADSOS # Verify that bpmd works IFDEF:LIVE !IFDEF:MAJOR_RUNTIME_VERSION_1 +# Issue: https://github.com/dotnet/diagnostics/issues/2459 +!IFDEF:ALPINE IFDEF:DESKTOP SOSCOMMAND:bpmd SymbolTestApp.exe SymbolTestApp.Program.Main @@ -52,6 +54,7 @@ CONTINUE SOSCOMMAND:ClrStack VERIFY:\s+\s+\s+SymbolTestApp\.Program\.Foo4\(.*\)\s+\[(?i:.*[\\|/]SymbolTestApp\.cs) @ 34\]\s* +ENDIF:ALPINE ENDIF:MAJOR_RUNTIME_VERSION_1 ENDIF:LIVE diff --git a/src/SOS/SOS.UnitTests/Scripts/StackAndOtherTests.script b/src/SOS/SOS.UnitTests/Scripts/StackAndOtherTests.script index 748409dad..c321762c8 100644 --- a/src/SOS/SOS.UnitTests/Scripts/StackAndOtherTests.script +++ b/src/SOS/SOS.UnitTests/Scripts/StackAndOtherTests.script @@ -9,6 +9,8 @@ LOADSOS # Verify that bpmd works IFDEF:LIVE !IFDEF:MAJOR_RUNTIME_VERSION_1 +# Issue: https://github.com/dotnet/diagnostics/issues/2459 +!IFDEF:ALPINE IFDEF:DESKTOP SOSCOMMAND:bpmd SymbolTestApp.exe SymbolTestApp.Program.Main @@ -48,6 +50,7 @@ CONTINUE SOSCOMMAND:ClrStack VERIFY:\s+\s+\s+SymbolTestApp\.Program\.Foo4\(.*\)\s+\[(?i:.*[\\|/]SymbolTestApp\.cs) @ 34\]\s* +ENDIF:ALPINE ENDIF:MAJOR_RUNTIME_VERSION_1 ENDIF:LIVE