简体   繁体   English

涵盖Windows资源管理器上下文菜单应用程序!

[英]Getting Coverage for Windows Explorer Context Menu Application!

I have an application which runs using the context menu of windows explorer. 我有一个使用Windows资源管理器的上下文菜单运行的应用程序。 I create an ATL based DLL and register it to Windows Registry under HKCR\\AllFileSystemObjects\\ShellEx\\ContextMenuHandlers. 我创建一个基于ATL的DLL,并将其注册到HKCR \\ AllFileSystemObjects \\ ShellEx \\ ContextMenuHandlers下的Windows注册表中。 I am able to run my application. 我能够运行我的应用程序。 I want coverage for my code present in the DLL which is being registered in the registry. 我希望覆盖在注册表中注册的DLL中存在的代码。

I am currently using IBM Rational Pure Coverage for my other applications. 我目前正在将IBM Rational Pure Coverage用于其他应用程序。 How to use it for getting coverage here? 如何在这里使用它来覆盖? In case of other normal applications, we can instrument the DLL using the Pure Coverage UI and run all the testcases. 对于其他普通应用程序,我们可以使用Pure Coverage UI检测DLL并运行所有测试用例。 But, in this case I am not clear how to go about the same? 但是,在这种情况下,我不清楚该怎么做? Also, if it is not possible using rational pure coverage, what are the other tools available? 此外,如果不可能使用理性的纯覆盖率,还有哪些其他可用工具?

After some amount of research, I have figured out the solution for this. 经过大量研究,我找到了解决方案。 In Pure Coverage there is a mechanism for instrumenting DLLs only. 在Pure Coverage中,有一种仅用于检测DLL的机制。 We can instrument a DLL in permanent instrumentation mode, so that whenever any exe invokes it, the coverage will be recorded. 我们可以在永久检测模式下检测DLL,以便每当一个exe调用它时,都会记录覆盖率。

With this mechanism, coverage can obtained for Windows Explorer Context Menu Application. 使用此机制,可以获得Windows资源管理器上下文菜单应用程序的覆盖范围。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM