Unit test explorer doesnt show all my tests

Not sure if this is a caching issue, but when i open my project which has about 350+ tests (mixed mstest and nunit), only about 50 or so appear in the unit test explorer.
Then, as i open each test class file, the explorer updates and shows those tests in the treeview. I've tried clearing resharper cache, pressing refresh icon, clean and rebuild solution and still get the same kind of behaviour.
using VS2013 update2 and latest resharper 8.2.1000.4556

Further to this some of the projects reference a 64bit assembly so i've also set all the test projects that call those projects to also be x64 too, thinking it might spin up the x64 test execution engine also.

Any help appreciated! thanks.

1
6 comments

Hello

  Are you able to reproduce the issue in a sample solution and send me it?

Thanks!

0

Ive created a sample project with 30 tests in the x86 project, and 20 tests in x64, on solution load the 30 tests appear in test explorer, but in x64 project only 10 of the 20 tests show until i open the test files. There is a mix of nunit and mstest, with different categories and some ignored others not.

using latest R# 8.2.1000.4556 and same behaviour occurs in both VS2012 (update 4 - 11.0.61030.00) and VS 2013 (Update 2 - 12.0.30501.00)



Attachment(s):
ResharperTestProjects.zip
0

Hi, I tried solution you attached. Everything works as expected, I can explain the behaviour you see:
First of all, NUnit tests are not affected at all, they all are loaded and runnable.
MSTest however doesn't support x86 and x64 tests in a single solution, so only x86 get loaded. So does VS Test Runner. If you'd like to run x64 you need to create .testsettings file with correct host setup. Obviously, in this case x86 can not be run. This is MSTest restriction we can not overcome at the moment.
We want to support such scenario in upcoming version, see related request: http://youtrack.jetbrains.com/issue/RSRP-336291

0

Hi Victor,

Further to this i've done a few more tests (using the attached test solution i provided in this post).

1. Changed both projects target platform to x86 => all tests appear after cache refresh/build/clean, re-open solution and rebuild.
2. Changed both projects target platform to x64 => repeated the refresh steps and only 20/30 tests from the first project show, and 10/20 tests of the 2nd project show.

Interestingly enough is that they are all NUNIT tests that load on start, no MSTests.
Screenshot provided (ignore the file/project naming. all projects set to X64)



Attachment(s):
nunit_tests_only_allprojects_x64target_platform.PNG
0

Hello

    Let's try doing the following:


  • Add .testsettings file to the solution;
  • Point ReSharper to use it via ReSharper | Options | Unit Testing | MSTest | Select Test Run Configuration | Use this Test Run Configuration;
  • Rebuild the solution;
  • Then open ReSharper | Unit Tests | Unit Tests dialog and check the list of tests;


Thanks!

1

Hi Alexander, i tried that and within the testsettings file i set "run 64bit processes on a 64bit machine" and cleaned/rebuilt and all the tests then appear.

0

Please sign in to leave a comment.