惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

美团技术团队
D
DataBreaches.Net
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
D
Docker
N
Netflix TechBlog - Medium
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
C
Check Point Blog
腾讯CDC
Stack Overflow Blog
Stack Overflow Blog
V
Visual Studio Blog
IT之家
IT之家
月光博客
月光博客
U
Unit 42
K
Kaspersky official blog
T
Threatpost
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
GbyAI
GbyAI
P
Proofpoint News Feed
Last Week in AI
Last Week in AI
云风的 BLOG
云风的 BLOG
酷 壳 – CoolShell
酷 壳 – CoolShell
I
InfoQ
Engineering at Meta
Engineering at Meta
Recorded Future
Recorded Future
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
S
Security @ Cisco Blogs
MyScale Blog
MyScale Blog
大猫的无限游戏
大猫的无限游戏
Security Archives - TechRepublic
Security Archives - TechRepublic
Webroot Blog
Webroot Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Hacker News - Newest:
Hacker News - Newest: "LLM"
S
Schneier on Security
S
Secure Thoughts
The Register - Security
The Register - Security
B
Blog RSS Feed
The Last Watchdog
The Last Watchdog
P
Palo Alto Networks Blog
爱范儿
爱范儿
B
Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
N
News and Events Feed by Topic
阮一峰的网络日志
阮一峰的网络日志
L
LINUX DO - 热门话题
C
Cisco Blogs
Spread Privacy
Spread Privacy
F
Full Disclosure
博客园 - 聂微东
T
The Blog of Author Tim Ferriss

博客园 - GDLMO

给12306的建议 在delphi中引用第三方控件时,找不到dcu的解决办法 使用SqlBulkCopy时应注意Sqlserver表中使用缺省值的列 在sqlserver中使用bcp自动导出数据的方法和注意事项 无法识别的属性“requirePermission” sqlserver,将视图或表的记录不重复的插入到另一个表 水平太差,虽然认为Linq是个好东东,但有谁能教教我,怎么调试? Sqlserver 插入一条记录时,不重复插入的办法 dnn5.5.1的配置 动态生成ASP.NET按钮时要注意的一个问题 关于EditUrl与NavigateURL的调用问题 DNN常用的几种页面跳转(EditUrl和Globals.NavigateURL) The Auto option has been disabled as the DotNetNuke Application cannot connect to a valid SQL Server database SQLite3中TimeStamp的使用问题 博文阅读密码验证 - 博客园 在DNN中使用SqlDataReader ExecuteReader(string connectionString, string spName, params object[] parameterValues)始终无法获得返回值 在DNN中使用jQuery的插件Validate Enter Null Values for DateTime Column of SQL Server(转) Web.Config和Sql Server2005连接字符串总结(转)
让单元测试项目也能同步测试主程序的APP.CONFIG
GDLMO · 2011-06-30 · via 博客园 - GDLMO

近期由于工作上的需要做了一个自动将数据更新到数据库的小程序,采用了插件的编程方式,为了能灵活的配置所需的插件,将插件的配置信息添加到APP.CONFIG中,但是单元测试时却有点小问题,测试项目的配置文件不能与主程序的配置文件同步更新,每次需手动同步。解决办法如下:

一、第一次需将主程序的APP.CONFIG复制到测试项目中。如下图1所示

复制配置文件 图1:将主程序的APP.CONFIG复制到测试项目

二、在测试项目的预生成事件中添加命令,如下图2所示

单元测试项目预生成事件图2: 测试项目的预生成事件

三、如果要实现其它的配置同步到测试项目,请参见“在VS2008中使用Nhibernate单元测试时无法找到hibernate.cfg.xml文件的解决方案