C# Visual Studio测试生成步骤找不到DLL

C# Visual Studio测试生成步骤找不到DLL,c#,unit-testing,tfs,msbuild,build-automation,C#,Unit Testing,Tfs,Msbuild,Build Automation,您好,我在TFS构建过程中有以下构建步骤 1) 构建代码 2) 运行测试 第一步有以下输入 解决方案:MyApp\TestApp*.sln MSBuild参数:/p:DeployOnBuild=True/p:DeployDefaultTarget=WebPublish/p:WebPublishMethod=FileSystem/p:DeleteExistingFiles=True/p:publishUrl=“D:\output” 然后在我的测试步骤中,我有以下内容 测试程序集:D:\output

您好,我在TFS构建过程中有以下构建步骤

1) 构建代码 2) 运行测试

第一步有以下输入

解决方案:MyApp\TestApp*.sln

MSBuild参数:/p:DeployOnBuild=True/p:DeployDefaultTarget=WebPublish/p:WebPublishMethod=FileSystem/p:DeleteExistingFiles=True/p:publishUrl=“D:\output”

然后在我的测试步骤中,我有以下内容

测试程序集:D:\output\bin*tests*.dll

当我运行它时,我得到以下警告 “未找到与模式匹配的测试程序集:'D:\output\bin*tests*.dll'


除了测试项目,所有的二进制文件都在那里。我如何告诉第一步也发布测试dll?这是正确的方法吗?因为我正在硬编码路径,有更好的方法吗?

这是因为我在发布模式下构建,而单元测试项目没有设置为在发布模式下构建