Fitnesse test fails with linq datacontext
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.
精彩评论