1.读取config
如测试类编译后为CyberSourceOperaterTest.dll,则配置文件应该为CyberSourceOperaterTest.dll.config
这样CyberSourceOperaterTest.dll.config中的ConnectionString等信息在被测试类中可以直接使用
2.如何才可以Debug测试类
右健单击测试工程->Property->Debug
把Start Action 设置为Start external program,路径设置为Nunit.exe位置
3.Log4net联合使用
在被测试类中使用了Log4net记录日志,同样需要在CyberSourceOperaterTest.dll.config设置log4net配置参数,并且加上
log4net.Config.XmlConfigurator.Configure();
如
[Test]
public void TestCreate()
{
log4net.Config.XmlConfigurator.Configure();
posted @ 2009-07-28 11:11 Terry82 阅读(316) 评论(0)
编辑
参考资料:
PRB:Response.WriteFile 无法下载大文件
http://support.microsoft.com/kb/812406/zh-cn
ASP.net下大文件上传的解决方案及WebbUpload组件源码
http://wucountry.cnblogs.com/archive/2005/12/28/306725.html
posted @ 2007-07-23 09:28 Terry82 阅读(154) 评论(0)
编辑
摘要: 在AjaxControlToolkit中有一个控件ReorderList可以实现拖动排序,它的示例程序用的是ObjectDataSource作数据源,而且数据没有保存到数据库中。我把它改成绑定到DataTable,并且数据是保存到数据库中。
阅读全文
posted @ 2007-05-24 11:15 Terry82 阅读(1217) 评论(3)
编辑
d.REMARK = this.txtRemark.Text;
当 txtRemark 文本为空时保存出错.
配置文件为
<property name="REMARK" type="String">
<column name="REMARK" length="200" sql-type="VARCHAR2" not-null="false"/>
</property>
解决方法
把配置文件改为
<property name="REMARK" type="Nullables.NHibernate.EmptyAnsiStringType, Nullables.NHibernate">
<column name="REMARK" length="200" sql-type="Nullables.NHibernate.EmptyAnsiStringType, Nullables.NHibernate" not-null="false"/>
</property>
当然要引入Nullables和Nullables.NHibernate这两个程序集.
posted @ 2006-05-11 11:47 Terry82 阅读(287) 评论(0)
编辑