Why do ReSharper and the built-in MSTest runner ignore my tests that aren't supposed to be ignored?

StackOverflow https://stackoverflow.com/questions/21690824

Pregunta

I'm running Visual Studio 2013 (with latest updates) with ReSharper 8.1 (latest stable version). I'm trying to run my tests as usual, but they keep acting as if they're ignored. Both Run Unit Tests (ReSharper) and Run Tests (built-in test runner) act as if the tests are ignored.

I've tried: restarting Visual Studio, uninstalling and reinstalling ReSharper, clearing ReSharper caches, rebooting my Windows 7 machine, removing all [Ignore] annotations throughout the project... nothing works.

Even a very simple test like:

    [TestMethod]
    public void CrapTest()
    {
        Assert.IsFalse(false);
    }

Will immediately go to an ignored state.

I've searched online but can't find any solutions. Help! This is driving me nuts.

¿Fue útil?

Solución

Deleting this file fixed it:

Solution Items / TestSettings.testsettings

One of our devs was trying to set up distributed testing for our TFS / CI test runs using this file.

Otros consejos

I know this is an old post, but identical symptoms can come from a different root cause. If a test case is marked Explicit then Resharper will ignore the test. In this case this is not an error, but rather works as designed.

<Test(), Explicit()>

Will cause tests to be ignored.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top