mardi 9 juin 2015

Unable to run DevExpress unit test without an exception thrown

When I create a unit test project with DevExpress in VS2012 it fails right out of the box with an exception in Microsoft.VisualStudio.TestPlatform.Core. Adding an Assert so the Sub actually does something doesn't help. No amount of building/rebuilding the project helps, nor does Reloading DevExpress. The code is simple:

<TestClass()> Public Class UnitTest1
    <TestMethod()> Public Sub TestMethod1()
        Assert.IsTrue(True)
    End Sub
End Class

I'm guessing something is misconfigured, but I have no idea what. The exception and full output are below.

Testing started:  

Total tests: 1, filtered: 1  

Exception:  
Message: An error occurred while initializing the settings provider named 'RunConfiguration'.  
Error: Invalid settings 'RunConfiguration'. Unexpected XmlElement: 'SolutionDirectory'.  
Source: Microsoft.VisualStudio.TestPlatform.Core  
StackTrace:  
    at Microsoft.VisualStudio.TestPlatform.Core.RunSettings.<>c__DisplayClass2.<CreateLazyThrower>b__1()  
    at Microsoft.VisualStudio.TestPlatform.Core.TestPluginsFramework.LazyExtension\`2.get_Value()  
    at Microsoft.VisualStudio.TestPlatform.Core.RunSettings.GetSettings(String settingsName)  
    at CR_VSTesting.Executor.Run(ExecuteTestData data, RunSettings settings, IEnumerable\`1 testCases)  
    at CR_VSTesting.Executor.Execute(ExecuteTestData data)  
InnerException:  
Exception:  
Message: Invalid settings 'RunConfiguration'. Unexpected XmlElement: 'SolutionDirectory'.  
Source: Microsoft.VisualStudio.TestPlatform.ObjectModel  
StackTrace:  
    at Microsoft.VisualStudio.TestPlatform.ObjectModel.RunConfiguration.FromXml(XmlReader reader)  
    at Microsoft.VisualStudio.TestPlatform.Extensions.RunConfigurationSettingsProvider.Load(XmlReader reader)  
    at Microsoft.VisualStudio.TestPlatform.Core.RunSettings.LoadSection(XmlReader reader, SettingsProviderExtensionManager settingsExtensionManager, Boolean reload)  
No tests found.  
Duration : 0.8022362  

Aucun commentaire:

Enregistrer un commentaire