加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Windows > 正文

命令行 – MSTest.exe没有复制所有需要的项目DLL?

发布时间:2020-12-14 04:03:59 所属栏目:Windows 来源:网络整理
导读:我正在尝试运行MSTest.exe,似乎没有正确读取testcontainer;我的测试都在Visual Studio中的所有配置环境中成功运行. 我正在使用的命令是: "C:Program Files (x86)Microsoft Visual Studio 10.0Common7IDEMSTest.exe" /nologo /usestderr /testSettings:
我正在尝试运行MSTest.exe,似乎没有正确读取testcontainer;我的测试都在Visual Studio中的所有配置环境中成功运行.

我正在使用的命令是:

"C:Program Files (x86)Microsoft Visual Studio 10.0Common7IDEMSTest.exe" /nologo /usestderr /testSettings:"C:tempMyProjectSourcesMyProjectLocal.testsettings" /searchpathroot:"C:tempMyProjectBinaries" /resultsfileroot:"C:tempMyProjectTestResults" /testcontainer:"C:tempMyProjectBinariesMyProject.Services.Server.UnitTests.dll"

testcontainer项目中的项目引用如下所示:

<ItemGroup>
    <ProjectReference Include="....ServicesMyProject.Services.ServerMyProject.Services.Server.csproj">
        <Project>{92EC1999-CC0C-47DD-A4D6-17C3B1233C50}</Project>
        <Name>MyProject.Services.Server</Name>
    </ProjectReference>
    <ProjectReference Include="....SvcConfigurationMyProject.ServiceConfiguration.InterfacesMyProject.ServiceConfiguration.Interfaces.csproj">
        <Project>{8E2E7BA9-75DB-458E-A184-AC1030EAD581}</Project>
        <Name>MyProject.ServiceConfiguration.Interfaces</Name>
    </ProjectReference>
    <ProjectReference Include="....SvcConfigurationMyProject.ServiceConfiguration.ServicesMyProject.ServiceConfiguration.Services.csproj">
        <Project>{39514766-23A8-45DB-96EA-B6B4D9C8B086}</Project>
        <Name>MyProject.ServiceConfiguration.Services</Name>
    </ProjectReference>
</ItemGroup>

ServiceConfiguration.Interfaces和ServiceConfiguration.Services DLL都没有放在TestResults的Out文件夹中.

项目GUID在引用和引用的项目之间匹配.

我在命令行中缺少什么?

mstest.exe不会羞辱所有引用的dll.

请参阅https://web.archive.org/web/20111221110459/http://www.dotnetthoughts.net/2011/11/22/mstest-exe-does-not-deploy-all-items/上的博客文章

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读