简体   繁体   English

ReSharper Unit Test Runner 忽略部署项配置

[英]ReSharper Unit Test Runner ignores deployment items configuration

I'm using Resharper 6.1 for unit testing a new project and it seems to ignore the the Deployment section of my local.testsettings file.我正在使用 Resharper 6.1 对新项目进行单元测试,它似乎忽略了我的 local.testsettings 文件的部署部分。

I tried to configure in "ReSharper -> Options -> Unit testing -> MSTest -> Use this test run configuration" to explicitly use the local.testsettings file, how is suggested in this question: ReSharper Unit Test Runner: Support for Deployment Items , but nothing happens.我尝试在“ReSharper -> 选项 -> 单元测试 -> MSTest -> 使用此测试运行配置”中进行配置以明确使用 local.testsettings 文件,在这个问题中如何建议: ReSharper Unit Test Runner: Support for Deployment Items ,但没有任何反应。

Desperately I tried to move the files out of the test project, create another Test Settings file, move the test project to another solution, but still nothing.绝望地我试图将文件移出测试项目,创建另一个测试设置文件,将测试项目移动到另一个解决方案,但仍然没有。

Any tips?有小费吗?

This issue (http://youtrack.jetbrains.com/issue/RSRP-295311) should be fixed in ReSharper 7 here: http://www.jetbrains.com/resharper/download/index.html . 此问题(http://youtrack.jetbrains.com/issue/RSRP-295311)应该在ReSharper 7中的以下位置得到解决: http : //www.jetbrains.com/resharper/download/index.html

Thank you! 谢谢!

This is also a ReSharper-Configuration problem that I encounter myself. 这也是我遇到的ReSharper-Configuration问题。 May this help you. 希望这对您有帮助。

When I try to run the application, it get this ReSharper error: "The project to be run with this configuration is not present in the solution" 当我尝试运行该应用程序时,它收到此ReSharper错误:“解决方案中不存在使用此配置运行的项目”

在此处输入图片说明

In Resharper help page, I found the path to the run configurations: https://www.jetbrains.com/help/resharper/2016.2/Run_Configurations.html 在Resharper帮助页面中,我找到了运行配置的路径: https : //www.jetbrains.com/help/resharper/2016.2/Run_Configurations.html

ReSharper | ReSharper | Tools | 工具| Run Configurations... 运行配置... 在此处输入图片说明

Since the project doesn't exist anymore, I delete that connfiguration: 由于该项目不再存在,因此我删除了该配置:

{Project Name} > Configure > Delete... {项目名称}>配置>删除... 在此处输入图片说明

I got the same ReSharper error in VS2019, VS2022:我在 VS2019、VS2022 中遇到了相同的 ReSharper 错误:

ReSharper – Failed to execute run configuration ReSharper - 无法执行运行配置

The project to be run with this configuration is not present in the solution.解决方案中不存在要使用此配置运行的项目。

Turns out that you don't have to necessarily run the project that is problematic.事实证明,您不一定非要运行有问题的项目。 If there is some configuration saved for another project in ReSharper, and that project is not present anymore (for example, you've switched branches or deleted some project from the solution), this error will pop-up.如果在 ReSharper 中为另一个项目保存了一些配置,并且该项目不再存在(例如,您切换了分支或从解决方案中删除了某个项目),则会弹出此错误。 It was my case.这是我的情况。

Solution is as described above:解决方法如上所述:

Go to Extensions -> ReSharper -> Tools -> Run configurations… -> nonExistingProject -> Configure -> Delete转到扩展 -> ReSharper -> 工具 -> 运行配置... -> nonExistingProject -> 配置 -> 删除

This will delete configuration that is preventing ReSharper to work well and blocks your run at the IDE.这将删除阻止 ReSharper 正常工作并阻止您在 IDE 中运行的配置。

Apparently, still not fixed...貌似还是没修好……

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM