Build Server Updated to VS 16.10.0 breaks elevated tests

1 Answer 200 Views
Continuous Integration
Josh
Top achievements
Rank 1
Josh asked on 02 Jun 2021, 03:35 PM

Over the weekend Visual Studio was upgraded to 16.10.0 on our self-hosted Azure DevOps agent server. This has caused all of our unit tests that rely on the JustMock profiler to begin failing with the Exception:

Failed {METHODNAME} [6 ms]
  Error Message:
   Test method {NAMESPACE}.{CLASSNAME}.{METHODNAME} threw exception: 
System.InvalidProgramException: Common Language Runtime detected an invalid program.
  Stack Trace:
      at {NAMESPACE}.{CLASSNAME}.{METHODNAME}()
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at {NAMESPACE}.{CLASSNAME}.{METHODNAME}()

We are using JustMock R2 2021, the Telerik JustMock VSTest v.2 (v2.6.1) pipeline task, and our test projects are targeting netcore3.1.

The tests run and pass when executed locally through Visual Studio (16.10.0) Test Explorer, but fail during pipeline execution. Nothing else has changed on the agent server except for the Visual Studio upgrade that I am aware of.

Pipeline YAML:

jobBuildAndPublishWebsite_${{ parameters.jobName }}
  displayName'Build and Publish Website - ${{ parameters.jobName }}'
  steps:
    - checkoutself
      cleantrue
      fetchDepth10
    - taskDotNetCoreCLI@2
      displayName'dotnet restore'
      inputs:
        commandrestore
        projects'**/*.csproj'
        vstsFeed${{ parameters.vstsFeedId }}
    - taskDotNetCoreCLI@2
      displayName'dotnet build'
      inputs:
        projects'**/*.csproj'
        arguments'--no-restore --nologo --configuration ${{ parameters.buildConfiguration }}'
taskJustMockVSTest@2
      displayName'Run Unit Tests'
      inputs:
        testAssemblyVer2: |
          **\*tests*.dll
          **\*Tests*.dll
          !**\*TestAdapter.dll
          !**\obj\**
          !**\packages\**
        pathTo64BitJustMockProfiler'$(System.DefaultWorkingDirectory)\lib\Telerik\JustMock\CodeWeaver\64\Telerik.CodeWeaver.Profiler.dll'
        pathTo32BitJustMockProfiler'$(System.DefaultWorkingDirectory)\lib\Telerik\JustMock\CodeWeaver\32\Telerik.CodeWeaver.Profiler.dll'
        vsTestVersionlatest
        runInParalleltrue
        codeCoverageEnabledtrue

 

1 Answer, 1 is accepted

Sort by
0
Mihail
Telerik team
answered on 04 Jun 2021, 01:38 PM

Hey Josh,

As I answered the ticket you've opened, I wasn't able to reproduce the described issue. I will appreciate it if you can send us the full build log. This way I will have more data on what is going on.

Regards,
Mihail
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
Continuous Integration
Asked by
Josh
Top achievements
Rank 1
Answers by
Mihail
Telerik team
Share this question
or