OpenCover + Xunit + JustMock Pro Seems to switch Profiler ID on run

3 posts, 0 answers
  1. Mark
    Mark avatar
    6 posts
    Member since:
    Aug 2010

    Posted 13 May 2015 Link to this post

    @SET JUSTMOCK_INSTANCE=1
    @SET COR_ENABLE_PROFILING=1
    @SET COR_PROFILER={B7ABE522-A68F-44F2-925B-81E7488E9EC0}

    When I run XUNIT, this works fine. : 

    xunit.console %TestsDLL% -nunit %ReportDirectory%\%CurrentProjectRunning%.%ldt%.xml

    Results: 

    .NET Runtime version 4.0.30319.0 - The profiler was loaded successfully.  Profiler CLSID: '{B7ABE522-A68F-44F2-925B-81E7488E9EC0}'.  

     No error the profiler seems to work. 

     

    When I run XUNIT from OpenCover it seems to lose these settings?

     OpenCover.console.exe -target:"c:\xunitrunner\xunit.console.exe" -mergebyhash -filter:"+[*]*" -targetargs:"%TestsDLL% -nunit %ReportDirectory%\%CurrentProjectRunning%.%ldt%.xml"  -output:%ReportDirectory%\%ldt%coverage.xml -register:user

    Results:

    .NET Runtime version 4.0.30319.0 - The profiler was loaded successfully.  Profiler CLSID: '{1542C21D-80C3-45E6-A56C-A9C1E4BEB7B8}'.  

    With this error:
    The profiler must be enabled to mock, arrange or execute the specified target.
    Detected active third-party profilers:
    * OpenCover (from process environment)
    Disable the profilers or link them from the JustMock configuration utility. Rest
    art the test runner and, if necessary, Visual Studio after linking.

     

  2. Mark
    Mark avatar
    6 posts
    Member since:
    Aug 2010

    Posted 13 May 2015 in reply to Mark Link to this post

    Looks like the OpenCover.DLL's were moved, but still showing in the JustMock "Easy Linking" profiler screens.

    Seem to have gotten by it just starting from scratch on registering again.  Now I don't get the Mock errors on opencover runs.

     

     

  3. DevCraft R3 2016 release webinar banner
  4. Kaloyan
    Admin
    Kaloyan avatar
    872 posts

    Posted 18 May 2015 Link to this post

    Hello Mark,
     
    I am glad to hear that you have been able to resolve the issue by yourself. Further, just in case, here is the JustMock's OpenCover integration article. I hope it helps.

    Regards,
    Kaloyan
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top