VSTS警告:请确保测试发现者&遗嘱执行人已注册,平台和框架版本设置合适,然后重试 [英] VSTS Warning : Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again

查看:93
本文介绍了VSTS警告:请确保测试发现者&遗嘱执行人已注册,平台和框架版本设置合适,然后重试的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试在VSTS CD任务Visual Studio Test下执行集成测试时,出现以下错误.

I have below error when try to execute integration tests under VSTS CD-task Visual Studio Test.

D:\ a \ r1 \ a \ SiteSearchFramework \ e2e \ XXX.SiteSearch.EndToEnd.Integration.Tests.dll中没有可用的测试.确保测试发现者&遗嘱执行人已注册,平台和框架版本设置合适,然后重试

我在下面的解决方案中尝试了一些选项,但是没有用.

I tried few options in below solution, didn't work though.

解决方案1 ​​

日志:

2018-12-30T01:15:07.5727307Z ##[section]Starting: VsTest - End2End Tests 2018-12-30T01:15:07.5735098Z ============================================================================== 2018-12-30T01:15:07.5735255Z Task : Visual Studio Test 2018-12-30T01:15:07.5735424Z Description : Run unit and functional tests (Selenium, Appium, Coded UI test, etc.) using the Visual Studio Test (VsTest) runner. Test frameworks that have a Visual Studio test adapter such as MsTest, xUnit, NUnit, Chutzpah (for JavaScript tests using QUnit, Mocha and Jasmine), etc. can be run. Tests can be distributed on multiple agents using this task (version 2). 2018-12-30T01:15:07.5735595Z Version : 2.144.9 2018-12-30T01:15:07.5735680Z Author : Microsoft Corporation 2018-12-30T01:15:07.5735860Z Help : [More information](https://go.microsoft.com/fwlink/?LinkId=835764) 2018-12-30T01:15:07.5735989Z ============================================================================== 2018-12-30T01:15:08.7136918Z SystemVssConnection exists true 2018-12-30T01:15:08.7303782Z SystemVssConnection exists true 2018-12-30T01:15:08.7401053Z Running tests using vstest.console.exe runner. 2018-12-30T01:15:08.7401220Z ====================================================== 2018-12-30T01:15:08.7401424Z Test selector : Test assemblies 2018-12-30T01:15:08.7401563Z Test filter criteria : null 2018-12-30T01:15:08.7401702Z Search folder : D:\a\r1\a 2018-12-30T01:15:08.8673368Z Run in parallel : false 2018-12-30T01:15:08.8673783Z Run in isolation : false 2018-12-30T01:15:08.8674157Z Path to custom adapters : D:\a\r1\a 2018-12-30T01:15:08.8675167Z Other console options : null 2018-12-30T01:15:08.8675533Z Code coverage enabled : false 2018-12-30T01:15:08.8676084Z Diagnostics enabled : true 2018-12-30T01:15:08.8676957Z SystemVssConnection exists true 2018-12-30T01:15:08.8680294Z Run the tests locally using vstest.console.exe 2018-12-30T01:15:08.8680531Z ======================================================== 2018-12-30T01:15:08.8680903Z Test selector : Test assemblies 2018-12-30T01:15:08.8681301Z Test assemblies : **\*\*.EndToEnd.Integration.Tests.dll 2018-12-30T01:15:08.8681656Z Test filter criteria : null 2018-12-30T01:15:08.8682253Z Search folder : D:\a\r1\a 2018-12-30T01:15:08.8682609Z Run settings file : D:\a\r1\a 2018-12-30T01:15:08.8683225Z Run in parallel : false 2018-12-30T01:15:08.8683646Z Run in isolation : false 2018-12-30T01:15:08.8686856Z Path to custom adapters : D:\a\r1\a 2018-12-30T01:15:08.8689056Z Other console options : null 2018-12-30T01:15:08.8689537Z Code coverage enabled : false 2018-12-30T01:15:08.8689740Z Diagnostics enabled : false 2018-12-30T01:15:08.8690648Z Rerun failed tests: false 2018-12-30T01:15:09.1368849Z VisualStudio version selected for test execution : toolsInstaller 2018-12-30T01:15:09.4782611Z ======================================================== 2018-12-30T01:15:09.4808305Z ====================================================== 2018-12-30T01:15:09.4945232Z [command]C:\hostedtoolcache\windows\VsTest\16.0.0-preview-20181205-02\x64\tools\net451\Common7\IDE\Extensions\TestPlatform\vstest.console.exe @D:\a\_temp\5987b5c1-0bd0-11e9-ab8a-2da31cef68f3.txt 2018-12-30T01:15:09.6112080Z Microsoft (R) Test Execution Command Line Tool Version 16.0.0-preview-20181205-02 2018-12-30T01:15:09.6112672Z Copyright (c) Microsoft Corporation. All rights reserved. 2018-12-30T01:15:09.6112863Z 2018-12-30T01:15:09.6577532Z vstest.console.exe 2018-12-30T01:15:09.6578059Z "D:\a\r1\a\SiteSearchFramework\e2e\XXX.SiteSearch.EndToEnd.Integration.Tests.dll" 2018-12-30T01:15:09.6578280Z /logger:"trx" 2018-12-30T01:15:09.6578485Z /TestAdapterPath:"D:\a\r1\a" 2018-12-30T01:15:11.6317213Z Starting test execution, please wait... 2018-12-30T01:15:14.2322930Z No test is available in D:\a\r1\a\SiteSearchFramework\e2e\XXX.SiteSearch.EndToEnd.Integration.Tests.dll. Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again. 2018-12-30T01:15:14.3430162Z Results File: D:\a\r1\a\TestResults\VssAdministrator_fv-az137_2018-12-30_01_15_14.trx 2018-12-30T01:15:14.3453569Z 2018-12-30T01:15:15.9470428Z ##[warning]Invalid results file. Make sure the result format of the file 'D:\a\r1\a\TestResults\VssAdministrator_fv-az137_2018-12-30_01_15_14.trx' matches 'VSTest' test results format. 2018-12-30T01:15:15.9596641Z ##[section]Async Command Start: Publish test results 2018-12-30T01:15:15.9596804Z ##[section]Async Command End: Publish test results 2018-12-30T01:15:15.9597264Z ##[section]Finishing: VsTest - End2End Tests

2018-12-30T01:15:07.5727307Z ##[section]Starting: VsTest - End2End Tests 2018-12-30T01:15:07.5735098Z ============================================================================== 2018-12-30T01:15:07.5735255Z Task : Visual Studio Test 2018-12-30T01:15:07.5735424Z Description : Run unit and functional tests (Selenium, Appium, Coded UI test, etc.) using the Visual Studio Test (VsTest) runner. Test frameworks that have a Visual Studio test adapter such as MsTest, xUnit, NUnit, Chutzpah (for JavaScript tests using QUnit, Mocha and Jasmine), etc. can be run. Tests can be distributed on multiple agents using this task (version 2). 2018-12-30T01:15:07.5735595Z Version : 2.144.9 2018-12-30T01:15:07.5735680Z Author : Microsoft Corporation 2018-12-30T01:15:07.5735860Z Help : [More information](https://go.microsoft.com/fwlink/?LinkId=835764) 2018-12-30T01:15:07.5735989Z ============================================================================== 2018-12-30T01:15:08.7136918Z SystemVssConnection exists true 2018-12-30T01:15:08.7303782Z SystemVssConnection exists true 2018-12-30T01:15:08.7401053Z Running tests using vstest.console.exe runner. 2018-12-30T01:15:08.7401220Z ====================================================== 2018-12-30T01:15:08.7401424Z Test selector : Test assemblies 2018-12-30T01:15:08.7401563Z Test filter criteria : null 2018-12-30T01:15:08.7401702Z Search folder : D:\a\r1\a 2018-12-30T01:15:08.8673368Z Run in parallel : false 2018-12-30T01:15:08.8673783Z Run in isolation : false 2018-12-30T01:15:08.8674157Z Path to custom adapters : D:\a\r1\a 2018-12-30T01:15:08.8675167Z Other console options : null 2018-12-30T01:15:08.8675533Z Code coverage enabled : false 2018-12-30T01:15:08.8676084Z Diagnostics enabled : true 2018-12-30T01:15:08.8676957Z SystemVssConnection exists true 2018-12-30T01:15:08.8680294Z Run the tests locally using vstest.console.exe 2018-12-30T01:15:08.8680531Z ======================================================== 2018-12-30T01:15:08.8680903Z Test selector : Test assemblies 2018-12-30T01:15:08.8681301Z Test assemblies : **\*\*.EndToEnd.Integration.Tests.dll 2018-12-30T01:15:08.8681656Z Test filter criteria : null 2018-12-30T01:15:08.8682253Z Search folder : D:\a\r1\a 2018-12-30T01:15:08.8682609Z Run settings file : D:\a\r1\a 2018-12-30T01:15:08.8683225Z Run in parallel : false 2018-12-30T01:15:08.8683646Z Run in isolation : false 2018-12-30T01:15:08.8686856Z Path to custom adapters : D:\a\r1\a 2018-12-30T01:15:08.8689056Z Other console options : null 2018-12-30T01:15:08.8689537Z Code coverage enabled : false 2018-12-30T01:15:08.8689740Z Diagnostics enabled : false 2018-12-30T01:15:08.8690648Z Rerun failed tests: false 2018-12-30T01:15:09.1368849Z VisualStudio version selected for test execution : toolsInstaller 2018-12-30T01:15:09.4782611Z ======================================================== 2018-12-30T01:15:09.4808305Z ====================================================== 2018-12-30T01:15:09.4945232Z [command]C:\hostedtoolcache\windows\VsTest\16.0.0-preview-20181205-02\x64\tools\net451\Common7\IDE\Extensions\TestPlatform\vstest.console.exe @D:\a\_temp\5987b5c1-0bd0-11e9-ab8a-2da31cef68f3.txt 2018-12-30T01:15:09.6112080Z Microsoft (R) Test Execution Command Line Tool Version 16.0.0-preview-20181205-02 2018-12-30T01:15:09.6112672Z Copyright (c) Microsoft Corporation. All rights reserved. 2018-12-30T01:15:09.6112863Z 2018-12-30T01:15:09.6577532Z vstest.console.exe 2018-12-30T01:15:09.6578059Z "D:\a\r1\a\SiteSearchFramework\e2e\XXX.SiteSearch.EndToEnd.Integration.Tests.dll" 2018-12-30T01:15:09.6578280Z /logger:"trx" 2018-12-30T01:15:09.6578485Z /TestAdapterPath:"D:\a\r1\a" 2018-12-30T01:15:11.6317213Z Starting test execution, please wait... 2018-12-30T01:15:14.2322930Z No test is available in D:\a\r1\a\SiteSearchFramework\e2e\XXX.SiteSearch.EndToEnd.Integration.Tests.dll. Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again. 2018-12-30T01:15:14.3430162Z Results File: D:\a\r1\a\TestResults\VssAdministrator_fv-az137_2018-12-30_01_15_14.trx 2018-12-30T01:15:14.3453569Z 2018-12-30T01:15:15.9470428Z ##[warning]Invalid results file. Make sure the result format of the file 'D:\a\r1\a\TestResults\VssAdministrator_fv-az137_2018-12-30_01_15_14.trx' matches 'VSTest' test results format. 2018-12-30T01:15:15.9596641Z ##[section]Async Command Start: Publish test results 2018-12-30T01:15:15.9596804Z ##[section]Async Command End: Publish test results 2018-12-30T01:15:15.9597264Z ##[section]Finishing: VsTest - End2End Tests

测试项目(XXX.SiteSearch.EndToEnd.Integration.Tests)参考:

Test Project (XXX.SiteSearch.EndToEnd.Integration.Tests) references :

推荐答案

xunit.runner.visualstudio添加到解决方案中,并确保将其复制以构建工件输出.

Add xunit.runner.visualstudio to the solution and make sure it was copied to build artifact output.

这篇关于VSTS警告:请确保测试发现者&遗嘱执行人已注册,平台和框架版本设置合适,然后重试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆