Fitnesse 测试因 linq datacontext 失败

发布于 2024-09-08 02:00:25 字数 515 浏览 3 评论 0原文

我的 Fitnesse 测试因 linq datacontext 失败。我已经尝试添加 suite.config,然后将应用程序配置添加到我的 c:\fitnesse 文件夹 - .jar 文件所在的位置。

我将 -c 选项 c:\Fitnesse\suite.config 添加到测试页面上的命令部分。这是 suite.config 文件: c:\fitnesse\myapp.config ^.svn$

这是 myapp.config 文件:

测试仍然失败:

public MyDataContext() : 
    base(ConfigurationManager.ConnectionStrings["mycon"].ConnectionString, 
         mappingSource
    ) 
{ 
    OnCreated(); 
}

有什么想法吗? 谢谢。

My fitnesse tests fail with linq datacontext. I already tried adding a suite.config and then app config to my c:\fitnesse folder - where the .jar file is.

I added -c option c:\Fitnesse\suite.config to the command section on the test page. Here's the suite.config file: c:\fitnesse\myapp.config ^.svn$

Here's the myapp.config file:

The test still fails here:

public MyDataContext() : 
    base(ConfigurationManager.ConnectionStrings["mycon"].ConnectionString, 
         mappingSource
    ) 
{ 
    OnCreated(); 
}

Any ideas?
Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

吃→可爱长大的 2024-09-15 02:00:25

您可以调用其他构造函数,也许找到一个不符合配置的构造函数?或者...它是一个分部类,因此您可以添加一个不会影响配置的构造函数(如果您还没有喜欢的构造函数)。

You could call other constructors, perhaps find a constructor that doesn't hit the config? Or... it's a partial class so you can add a constructor that doesn't hit the config if you don't already have one you like.

暗藏城府 2024-09-15 02:00:25

使用 -a 选项:

http://www.syterra.com/Fit/AppConfigFile.html< /a>

应用程序配置文件的套件配置代码中有一个错误 - 将在下一版本中修复。

Use the -a option:

http://www.syterra.com/Fit/AppConfigFile.html

There's a bug in the suite config code for app config files - will be fixed in the next release.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文