someone told me, don't do that. Framework should free the com reference for you. but...
if you are writing a AddIn for PowerPoint, you might have seen the same problem. That is, if you reference a element of GroupItems without release it immediately, next time, you group it into bigger group, and t ...
- 22:46
- 浏览 (807)
- 评论 (0)
http://www.infoq.com/news/2007/10/next-gen-functional-testing
pretty easy:
UI automation testing is the key thing
Distributed running tests in Virtualized environment is critical
BA's lo-fi prototype should be testing script
BA's acceptance criteria should be testing script
QA's automation testing ...
- 09:45
- 浏览 (530)
- 评论 (0)
问题场景:
有一个方法类似于下面的状况:
...
if (condition1) {
...
}
else {
...
}
...
if (condition2) {
...
}
else {
...
}
...
那么你该写几个测试来覆盖这段代码呢?答案是四个。
如果你有三个条件呢?答案是八个。
那么更多呢?。。。
解决办法:
...
do_first_thing();
...
do_second_thing();
...
抽取出两个方法。然后针对每个抽取的方法来写测试。而对原来的那个方法,只需要写一个测试了。
- 16:10
- 浏览 (520)
- 评论 (0)
public interface IBlock
{
string Quote();
void Append(char c);
bool ShouldAppendQuotedBlock(char c);
}
public abstract class NestedBlock : IBlock
{
private readonly NestedBlock parent;
private readonly List<IBlock> blocks; ...
- 19:14
- 浏览 (492)
- 评论 (0)
有三个主要的障碍:
1、服务器解析不到客户端的assembly,因为callback的代码在客户端的assembly中
2、TypeFilterLevel默认不是Full
3、普通callback代码不能访问客户端的变量,因为不是serializable的
解决办法:
1、利用AppDomain的AssemblyResolve事件,让自己来处理assembly的查找逻辑。并且让客户端在开始的时候把自己的assembly位置发给服务器。
2、
BinaryServerFormatterSinkProvider serverFormatter = new BinaryServerFormat ...
WPF
Drag drop not working when used in outlook
Topmost is not "topmost" when change screen resolution
Context menu overlapped by transparent window sometime
Click through, underlying window can get the mouse click event [*] even it do not have mouse capture
focus could remain in collapsed visu ...
- 10:48
- 浏览 (492)
- 评论 (0)
新建class时:
考虑对象的拷贝语义(copyable?)
新建member function时:
如果不改变对象状态,在声明后面加const(和ruby的!开头的方法一样)
新建function parameter时:
如果是传值的,而且是复杂对象,尽量使用const ValueType &
尽量把值放在shared_ptr中,然后把只传递指针(和C#与JAVA一样)
新建virtual member function时:
是不是要把destructor也声明成virtual的?
是不是要声明成pure virtual的
实例化对象时:
如果能实例化在栈上最好
不能,把指针 ...
- 15:32
- 浏览 (562)
- 评论 (0)
我的相册
step2
共 6 张
共 6 张
最近加入圈子
最新评论
-
汉语编程,有搞头
就E语言算巴 没用过也没计划用 CHTML不错哈哈
-- by lwwin -
关于estimation的闲言碎语
1. BA是Business Analyst的缩写,就是写story的人.2. ...
-- by taowen -
关于estimation的闲言碎语
请教:1.BA是什么意思?Business Analyzer?2.“好的esti ...
-- by movingboy -
计划经济体制的CMM,市场 ...
有创意,有启发性。顶!!
-- by estest -
贫血的Domain Model
看了这么久的领域模型,争论的真是没完没了。 难道就不能跳开这个领域模型或者还领域 ...
-- by hunter001201







评论排行榜