我们正在开发Visual Studio 2010和TFS 2010.我们有自己的BuildTemplate,它是默认模板的副本,但有一些附加内容,如(创建目录...),但主要的一点是,所有这些都在DefaultTemplate中 - 离开了.
我们已经进行了"单元"测试,这些测试也在起作用.我制作了运行所有单元测试的Build定义.已阅读此处的信息 - http://geekswithblogs.net/jakob/archive/2009/06/03/tfs-team-build-2010-running-unit-tests.aspx 以及其他许多地方.
构建运行非常完美,唯一不起作用的是构建摘要 - 测试结果,代码覆盖率,如上面的链接.
因此,当我在构建应用程序时查看活动日志时,它显示:
Run MSTest for Test Assemblies
c:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe /nologo /usestderr /testSettings:"C:\Builds\7\**Project**\**BuildName**\Sources\**ProgramName**\**ProgNameAndVersion**\Solutions\**SolutionName**\localtestrunDebug.testrunconfig" /searchpathroot:"C:\Builds\7\**Project**\**BuildName**\Binaries" /resultsfileroot:"C:\Builds\7\**Project**\**BuildName**\TestResults" /testcontainer:"C:\Builds\7\**Project**\**BuildName**\Binaries\**TestProjectName**.dll" /publish:"http://***:8080/tfs/MSLN" /publishbuild:"***:///Build/Build/14599" /teamproject:"**ProjectName**" /platform:"x86" /flavor:"**Release**"
Loading C:\Builds\7\**Project**\**BuildName**\Sources\**ProgramName**\**ProgNameAndVersion**\Solutions\**SolutionName**\localtestrunDebug.testrunconfig...
Loading C:\Builds\7\**Project**\**BuildName**\Binaries\**TestProjectName**.dll...
Starting execution...
Results Top Level Tests
------- ---------------
Failed ***.Test.***
Failed ***.Test.***
Failed ***.Test.***
Passed ***.Test.***
Passed ***.Test.***
Inconclusive ***.Test.***
Inconclusive ***.Test.***
Passed ***.Test.***
<many other tests>
...
5/154 test(s) Passed, 147 Failed, 2 Inconclusive
Summary
-------
Test Run Failed. …Run Code Online (Sandbox Code Playgroud) 当使用 VS2017 创建有状态解决方案并生成标准样板代码时,生成的两个项目具有两个不同的 MSBuild 版本。该应用程序使用 MSBuild 版本 1.5.0。该服务使用 MSBuild 版本 1.6.0(当前“最新”)。
如果我以这种方式运行该解决方案,它在我的本地 Service Fabric 群集上运行良好。
但是,当我使用 NuGet 将应用程序的 MSBuild 更新到 1.6.0 后(因此应用程序和服务器项目都使用相同的版本),会出现以下错误。
Severity Code Description Project File Line Suppression State
Error The OutputPath property is not set for project 'gt_strd5.sfproj'. Please check to make sure that you have specified a valid combination of Configuration and Platform for this project. Configuration='Debug' P follow a project-to-project reference to this project, this project has belatform='x64'. This error may also appear if some other …Run Code Online (Sandbox Code Playgroud) 我们最近更新了REST集成测试的依赖项,该测试使用了Groovy,HTTPBuilder,JSONAssert和Junit.当我们从HTTPBuilder 0.5.2到0.6时,我们的许多测试都失败了.
我们发现由于HTTPBuilder中的一个新"功能"提供了"对已注册内容类型的自动响应解析",响应格式发生了变化.
旧的,(0.5.2)格式,预期响应:
[
{
"name":"Portfolio_REST_Test01",
"description":"",
"referenceValueType":"Net Value",
"unitType":"SHARES",
"tags":[]
}
]
新的(0.6.2)响应格式:
[{tags=[], referenceValueType=Net Value, unitType=SHARES, description=, name=Portfolio_REST_Test01}]
Run Code Online (Sandbox Code Playgroud)
当JSONAssert尝试解析值为空字符串的命名值时,会出现问题,请参阅上面示例中的"描述".JSONAssert期望一个字符遵循等号而不是逗号,并在遇到时抛出异常.
build ×1
c# ×1
groovy ×1
httpbuilder ×1
json ×1
jsonassert ×1
msbuild ×1
tfs2010 ×1
tfsbuild ×1
unit-testing ×1