Every time I try to run a unit test with some test methods, I get a NullReferenceException at the first line of the following :
public DB()
{
this.sqlConnectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString;
this.con = new SqlConnection(this.sqlConnectionString);
this.con.StateChange += new StateChangeEventHandler(this.Connection_StateChange);
}
After further research I realized I should add an app.config file to my test project. I have no clue what to do with it or what it's used for, though.
Tips on how to proceed?