为什么我测试的总会报很多错误呢,比如测试方法
public void PrepareMonthlySalesAmtStatement(Month from, Month to)
{
DateTime dtmFrom = new DateTime(from.GetYear(), from.GetMonth(), 1);
DateTime dtmTo = new DateTime(to.GetYear(), to.GetMonth(), 1);
string strSql = "SELECT DatePart(yy, a.Date) AS intYear, DatePart(m, a.Date) AS intMonth, Sum(a.Sales_Amt * a.Exch_Rate) AS numTotSalesAmt FROM " + wuser.CurrentCorpDB + "..Sales_1 a, " + ConnManager.Basedb + "..CorpBusiPartner c WHERE a.Date >='" + dtmFrom.ToString("yyyyMMdd") + "' AND a.Date<'" + dtmTo.AddMonths(1).ToString("yyyyMMdd") + "' AND c.nvrCorpCode = '" + this.m_Code + "' AND a.Cust_no=c.nvrGenCode GROUP BY DatePart(m, a.Date), DatePart(yy, a.Date) ORDER BY DatePart(yy, a.Date), DatePart(m, a.Date);";
m_SqlStatement += strSql;
}
会报C:\svnhome\trunk\mutantdesign.xml.documentation\MemberInfoUtilities.cs(45): TestCase 'M:CECERP.Libraries.Objects.Corporation.CorpBusiPartner.PrepareMonthlySalesAmtStatement(CECERP.Libraries.Functions.DateTime.Month,CECERP.Libraries.Functions.DateTime.Month)' failed: 找不到文件或程序集名称“CECERP.Libraries.Functions.DateTime”,或找不到它的一个依赖项。
System.IO.FileNotFoundException: 找不到文件或程序集名称“CECERP.Libraries.Functions.DateTime”,或找不到它的一个依赖项。
文件名: “CECERP.Libraries.Functions.DateTime”
at System.Reflection.RuntimeMethodInfo.InternalGetParameters()
at System.Reflection.RuntimeMethodInfo.GetParameters()
at MutantDesign.Xml.Documentation.MemberInfoUtilities.getMemberFullName(MemberInfo member) in C:\svnhome\trunk\mutantdesign.xml.documentation\MemberInfoUtilities.cs:line 44
at MutantDesign.Xml.Documentation.MemberInfoUtilities.GetNameForMember(MemberInfo member) in C:\svnhome\trunk\mutantdesign.xml.documentation\MemberInfoUtilities.cs:line 14
at MutantDesign.Xml.Documentation.MemberInfoUtilities.FindMemberInfo(Assembly assembly, String xmlName) in C:\svnhome\trunk\mutantdesign.xml.documentation\MemberInfoUtilities.cs:line 146
at TestDriven.TestRunner.TestPathUtils.findAssemblyNamespaceTypeMethodFromXmlDocName(Assembly assembly, String xmlName, String& ns, Type& type, MethodInfo& method) in C:\svnhome\trunk\TestDriven.NET\TestDriven.TestRunner\TestPathUtils.cs:line 38
at TestDriven.TestRunner.TestPathUtils.FindAssemblyNamespaceTypeMethod(Assembly assembly, String testPath, String& ns, Type& type, MethodInfo& method) in C:\svnhome\trunk\TestDriven.NET\TestDriven.TestRunner\TestPathUtils.cs:line 20
at NUnitAddin.NUnit.TestRunner.NUnitTestRunner.Run(ITestListener testListener, ITraceListener traceListener, String assemblyPath, String xmlDocPath)
at TestDriven.TestRunner.AdaptorTestRunner.Run(ITestListener testListener, ITraceListener traceListener, String assemblyPath, String testPath) in C:\svnhome\trunk\TestDriven.NET\TestDriven.TestRunner\AdaptorTestRunner.cs:line 34
at TestDriven.TestRunner.Runner.Run() in C:\svnhome\trunk\TestDriven.NET\TestDriven.TestRunner\ThreadTestRunner.cs:line 93
=== Pre-bind state information ===
LOG: DisplayName = CECERP.Libraries.Functions.DateTime, Version=1.0.1847.27122, Culture=neutral, PublicKeyToken=null
(Fully-specified)
LOG: Appbase = D:\ITurbo\Source\CECERP\Libraries\Objects\Corporation\bin
LOG: Initial PrivatePath = NULL
Calling assembly : CECERP.Libraries.Objects.Corporation, Version=1.0.2099.21473, Culture=neutral, PublicKeyToken=null.
===
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Post-policy reference: CECERP.Libraries.Functions.DateTime, Version=1.0.1847.27122, Culture=neutral, PublicKeyToken=null
LOG: Attempting download of new URL file:///D:/ITurbo/Source/CECERP/Libraries/Objects/Corporation/bin/CECERP.Libraries.Functions.DateTime.DLL.
LOG: Attempting download of new URL file:///D:/ITurbo/Source/CECERP/Libraries/Objects/Corporation/bin/CECERP.Libraries.Functions.DateTime/CECERP.Libraries.Functions.DateTime.DLL.
LOG: Attempting download of new URL file:///D:/ITurbo/Source/CECERP/Libraries/Objects/Corporation/bin/CECERP.Libraries.Functions.DateTime.EXE.
LOG: Attempting download of new URL file:///D:/ITurbo/Source/CECERP/Libraries/Objects/Corporation/bin/CECERP.Libraries.Functions.DateTime/CECERP.Libraries.Functions.DateTime.EXE.
这样的错误