Regression: System.Runtime.Tests fail with "Missing a required constructor" on System.Reflection.PseudoCustomAttribute._GetSecurityAttributes
call CoreRun.exe xunit.console.netcore.exe System.Runtime.Tests.dll -xml testResults.xml -notrait Benchmark=true -notrait category=nonnetcoreapp1.1tests -notrait category=OuterLoop -notrait category=failing -notrait category=nonwind owstests xUnit.net console test runner (64-bit .NET Core) Copyright (C) 2014 Outercurve Foundation.
Discovering: System.Runtime.Tests
Discovered: System.Runtime.Tests
Starting: System.Runtime.Tests
System.Tests.GetCustomAttribute.NegTest1 [FAIL]
Assert.Throws() Failure
Expected: typeof(System.Reflection.AmbiguousMatchException)
Actual: typeof(System.Runtime.InteropServices.COMException): Missing a required constructor. (Exception from HRESULT: 0x8013143B)
Stack Trace:
at System.Reflection.PseudoCustomAttribute._GetSecurityAttributes(RuntimeModule module, Int32 token, Boolean assembly, Object[]& securityAttributes)
at System.Reflection.PseudoCustomAttribute.GetCustomAttributes(RuntimeAssembly assembly, RuntimeType caType, Boolean includeSecCa, Int32& count)
at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeAssembly assembly, RuntimeType caType)
at System.Attribute.GetCustomAttributes(Assembly element, Type attributeType, Boolean inherit)
at System.Attribute.GetCustomAttribute(Assembly element, Type attributeType, Boolean inherit)
D:\git\corefx\src\System.Runtime\tests\System\Attributes.netstandard1.7.cs(256,0): at System.Tests.GetCustomAttribute.<>c__DisplayClass2_0.
=== TEST EXECUTION SUMMARY === D:\git\corefx\Tools\tests.targets(260,5): warning : System.Runtime.Tests Total: 10501, Errors: 0, Failed: 4, Skipped: 0, Time: 1.910s [D:\git\corefx\src\System.Runtime\tests\System.Runtime.Tests.csproj] The previous error was converted to a warning because the task was called with ContinueOnError=true. Finished running tests. End time= 9:36:42.45, Exit code = 4 D:\git\corefx\Tools\tests.targets(260,5): warning MSB3073: The command "D:\git\corefx\bin/tests/AnyOS.AnyCPU.Debug/System.Runtime.Tests/default.netcoreapp1.1/netcoreapp1.1/RunTests.cmd D:\git\corefx\packages/" exited with code 4. [D:\gi t\corefx\src\System.Runtime\tests\System.Runtime.Tests.csproj]
This seems to be fallout from https://github.com/dotnet/corefx/commit/9b270c7b06751ab24d98d1404e4fd671c63aeb9e
/cc @weshaggard @joperezr @danmosemsft
Assigning to @danmosemsft as he likely introduced the regression (feel free to reassign).
Looking
I'll keep this open and assign to me just to track the re-enabling of those tests once we consume @jkotas coreclr fix.
@joperezr do you understand why this didn't fail in CI? it's not outer loop and it doesn't seem related to testing against latest bits (?)
Never mind I see your other message.