unit-testing – 无法加载应用程序或执行命令’Microsoft.Dnx.Te
发布时间:2020-12-14 02:47:17 所属栏目:Windows 来源:网络整理
导读:试图在VS2015中测试ASPNET 5应用程序. { "version": "1.0.0-*","description": "HoldingTank Class Library","dependencies": { "EntityFramework.InMemory": "7.0.0-rc1-final","FluentAssertions": "4.1.1","GenFu": "1.0.4","MyMVCProject": "1.0.0-*","x
试图在VS2015中测试ASPNET 5应用程序.
{ "version": "1.0.0-*","description": "HoldingTank Class Library","dependencies": { "EntityFramework.InMemory": "7.0.0-rc1-final","FluentAssertions": "4.1.1","GenFu": "1.0.4","MyMVCProject": "1.0.0-*","xunit": "2.1.0","xunit.runner.visualstudio": "2.1.0" },"commands": { "test": "xunit.runner.dnx" },"frameworks": { "dnx451": { } } } 但是,测试资源管理器窗口中没有显示任何测试,当我点击F5时,我得到: ------ Discover test started ------ ------ Test started: Project: HoldingTank ------ Starting Microsoft.Dnx.TestHost [C:Userserik.dnxruntimesdnx-clr-win-x86.1.0.0-rc1-update1bindnx.exe --appbase "C:codePortalSolutionsrcHoldingTank" Microsoft.Dnx.ApplicationHost --port 52620 Microsoft.Dnx.TestHost --port 56351 --parentProcessId 8368] Error: Unable to load application or execute command 'Microsoft.Dnx.TestHost'. Available commands: test. Unable to start Microsoft.Dnx.TestHost ========== Discover test finished: 0 found (0:00:01.8238001) ========== 我只有一个测试,用[事实]装饰,但它看起来并没有那么远. 查看“无法加载”错误的类似问题(但找不到任何特定的TestHost),我已经尝试确保测试项目和应用程序都针对相同的框架,但找不到任何差异.我在事件日志中看不到任何内容. 有什么建议? – 甚至不确定从哪里开始解决这个问题. 解决方法
您必须将“xunit.runner.dnx”添加为依赖项而不是“xunit.runner.visualstudio”.然后它将在VisualStudio中工作.
由于ASP.Net 5处于测试阶段,xunit.runner.dnx也是如此.使用与ASP.Net RC1匹配的当前预发布…我目前使用2.1.0-rc1-build204与ASP.Net 5 RC1 (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- windows-server-2008 – 是否可以为服务器上的单个帐户禁用
- 设置windows 10 wifi
- windows-server-2008 – 使用SSLv3 – 启用Strong Ciphers
- [UWP]占领标题栏
- 命令行界面 – 从Windows命令行导入.cer证书
- media-player – 如何在WP 8.1中访问媒体库?
- psql:致命错误:用户“postgres”WINDOWS的密码验证失败
- windows-8 – ManipulationMode解释
- windows-server-2003 – 当服务器运行时,Windows到计划任务
- Windows Azure中的关联组是否收费以及如何将现有服务一起移
推荐文章
站长推荐
热点阅读