开发者

Fitnesse test fails with linq datacontext

开发者 https://www.devze.com 2023-01-05 05:48 出处:网络
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.

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.


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.


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.

0

精彩评论

暂无评论...
验证码 换一张
取 消