簡體   English   中英

帶有 TFS2015 和 VisualStudio2015 的 xUnit 沒有找到任何測試

[英]xUnit with TFS2015 and VisualStudio2015 doesn't find any test

我有一個帶有以下 project.json 的 xUnit 測試項目:

"dependencies": {
  "xunit": "2.1.0-beta2-*",
  "xunit.runner.dnx": "2.1.0-beta2-*"
},

"commands": {
  "test": "xunit.runner.dnx"
},

"frameworks": {
  "dnx451": { },
  "dnxcore50": {
    "dependencies": {
      "System.Collections": "4.0.10-beta-22816",
      "System.Linq": "4.0.0-beta-22816",
      "System.Threading": "4.0.10-beta-22816",
      "Microsoft.CSharp": "4.0.0-beta-22816"
    }
  }
}

我的 Buildserver 能夠正確構建所有內容,但通過嘗試測試它給了我以下消息:

2015-05-17T18:41:26.0903225Z Warning: No test is available in C:\TfsData\Build\_work\c55817e8\...\artifacts\bin\

我的 Buildserver 與TFS2015一起運行,我安裝了VisualStudio 2015RC 我發現了類似的問題,但只是關於 TFS2013,這對我沒有幫助,因為 TFS2015 中沒有 TestAgent。 現在 xUnit-"Util" 通過 json 文件包含在 NuGet 中。

使用 VisualStudio 進行測試工作正常,即使在 VS 的服務器安裝中也是如此。

VisualStudio 中測試資源管理器的屏幕截圖

有人可以給我一個提示,如何解決這個問題?

Visual Studio 中的 DNX 支持很可能還沒有進入 TFS Build。 它不使用其他 xUnit.net 測試類型的標准測試發現,而是使用 ASP.NET 團隊添加到 Visual Studio 以支持任何基於project.json的項目中的單元測試的東西。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM