MSTest的DeploymentItem输出目录中testsettings [英] MsTest DeploymentItem OutputDirectory in testsettings

查看:238
本文介绍了MSTest的DeploymentItem输出目录中testsettings的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我怎么可以指定输出目录,当我在testsettings创建DeploymentItem?这是很容易当你申请DeploymentItem属性方法或类(有一个特殊的构造函数的参数),但我不明白的方式,将其应用在testsettings(甚至用户界面不包含这样的事)。

How can I specify output directory when I create DeploymentItem in testsettings? It is easy when you apply DeploymentItem attribute to method or class (there is a special constructor parameter) but I don't see a way to apply it in testsettings (and even UI doesn't contain anything like this).

推荐答案

尝试编辑的 testrunco​​nfig 的文件,无论是从VS或使用XML编辑器 - 右键点击并选择的开放并添加一行像这样的:

Try editing the testrunconfig file either from VS or using an XML editor - right-click and choose open with and add a line like this one:

<Deployment>
    <DeploymentItem filename="rootdir\SomeDir\" outputDirectory="SomeDir" />

这篇关于MSTest的DeploymentItem输出目录中testsettings的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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