依赖性分析工具-更新回归测试用例 [英] Dependencies analysis tool - updating regression test cases

查看:187
本文介绍了依赖性分析工具-更新回归测试用例的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题

我想思考的是一个非常普遍的问题。添加新代码会导致回归-现有测试用例变得过时。代码中的依赖性意味着即使您知道如何解决此特定的回归问题,也可能在两个方向上的另外N个地方进行间接回归-传入和传出。

Its quite a common problem I would like to think. Adding new code translates into regression - existing test cases become obsolete. Dependencies within the code mean even if you know how to fix this particular regression, there could be indirect regression at n more places in both directions - Afferent and Efferent.

要求

我有一家经营SVN,Maven + Nexus,Sonar,Jenkins和JIRA,QC,QTP的商店。总而言之,这是一个良好的CI环境。

I have a shop running SVN, Maven+Nexus,Sonar,Jenkins and JIRA,QC,QTP. All in all a good CI environment.

每次构建新版本时,我都会遇到新的回归案例。我想在两个方向上都找到Java包依赖关系,并适当地更新测试用例,以便涵盖所有类型的回归-直接和间接。
这是一个更大的问题,因为我的单元测试覆盖率甚至没有达到50%,并且集成测试的自动化跟不上开发的步伐。

With every new build I'll have new cases of regression. I want to find Java package dependencies in both directions and to update the test cases properly so as to cover all types of regression - direct and indirect. This is more of a problem as my unit test coverage is not even approaching 50% and automation of integration tests is not keeping pace with the development.

我的选项


  1. SONAR

  2. Google CodePRo

  3. JArchitect

  4. Jtest (进行了讨论

  5. 利用我拥有的 Atlassian 现有环境 strong>插件

  6. Kalisitck (供应商演示-不错的工具-涉及学习曲线和成本)

  7. 覆盖范围(例如Kalistick-学习曲线和复杂的安装。非常昂贵的许可证。

  8. 任何其他开源/付费的吗?

  1. SONAR
  2. Google CodePRo
  3. JArchitect
  4. Jtest ( Had a discussion with the vendor Parasoft. They do not have a tool for this)
  5. Leverage the existing environment I have with, lets say, an Atlassian plugin
  6. Kalisitck (Vendor demo - Nice tool - involves a learning curve and cost)
  7. Coverity (Like Kalistick - learning curve and complex installation.Very expensive license.
  8. Any other open source/paid ?

JArchitect,SONAR和CodePro将为您提供一个简单的矩阵,例如。告诉我哪个用户使用的类受到影响,哪个满足我的要求的一半。我想要走的更远,然后让工具告诉我哪些相应的测试用例受到影响,以及是否需要更新和/或执行它们以弥补回归风险。

JArchitect, SONAR and CodePro will give you a simple Matrix like this or this. Which satisfies half of my requirement by telling me which user and used-by classes are impacted. What I want is go 1 step further and have the tool tell me which corresponding test cases are impacted and if I need to update and/or execute them so as to cover my regression risks.

Kalstick,Coverity以及其他人可能会做我想要的-它们繁琐的设置和配置,随着您的系统的增长而缓慢,因此无法立即生效,要付出代价,并且需要学习曲线。

Kalistick, Coverity and maybe others might do what I want - they are heavy to setup and configure, grow with your system slowly so are not productive right away, come with a cost and need a learning curve.

简短问题

上面可以使用哪些工具设置时要考虑所有因素,例如安装,学习曲线,成本,可用性或任何其他参数。

Which tool(s) from above to use in my setup considering all factors like installation, learning curve, cost, availability or any other parameter.

我已经阅读了,诸如
https ://stackoverflow.com/questions/3716203/automatic-code-quality-and-architecture-quality-static-code-analysis
对什么的迷恋是什么
和许多链接的度量,但是它们不能回答我的特定问题。

I have already read the FAQ section on static-analysis, few threads like Static Analysis tool recommendation for Java? , https://stackoverflow.com/questions/3716203/automatic-code-quality-and-architecture-quality-static-code-analysis and What is the fascination with code metrics? and many linked ones, but they don't answer my specific question.

推荐答案

某些工具可能会有所帮助。请注意,并非所有人都与CI集成。

Some tools which might help. Note not all of them intergrate with CI.

iPlasma 是个很棒的工具

CodePro 是一个Eclipse插件,可帮助检测代码和设计问题(例如重复的代码,破坏封装的类或放置在错误类中的方法) )。 (现在由 Google 收购)

CodePro is an Eclipse Plugin which help in detecting code and design problems (e.g. duplicated code, classes that break encapsulation, or methods placed in a wrong class). (Now acquired by Google )

救济是一种可视化Java项目以下参数的工具:
size包的数量,即它包含多少个类和接口
可视化的项目种类(包和类表示为盒子,接口和类型的字段表示为球形)。
使用某项物品的重量(表示为重力,即中心距离)
依赖项数(表示为深度)。

Relief is a tool visualizing the following parameters of Java projects: size of a package, i.e. how many classes and interfaces it contains the kind of item being visualized (Packages and classes are represented as boxes, interfaces and type's fields as spheres). how heavy an item is being used (represented as gravity, i.e. distance of center) number of dependancies (represented as depth).

< a href = http://stan4j.com/general/download-ide.html rel = nofollow> Stan4j 是一种商业工具,价格为数百美元。它只针对Java项目,非常接近(或不确定?)Sonar。它具有良好的Eclipse集成。

Stan4j is a commercial tool that costs a couple of hundred $. It is targeting only Java projects, comes very close to (or a little better reports than? not sure) Sonar. It has a good Eclipse integration.

Intellij依赖性分析

据我所知,您需要跟踪两个OO指标-
传出耦合(Ca)传入耦合(Ce)。这样,您可以缩小到所需的软件包。您可以探索编写eclipse插件的机会,该插件在每次构建时都可以-根据Ca,Ce指标突出显示所需的类。

From what I could understand from your problem is that - you need to track two OO metrics - Efferent Coupling (Ca) and Afferent Couplings (Ce). With this you can narrow down to the required packages. You can explore the oppurtunity of writing an eclipse plugin which on every build - can highlight the required classes based on the Ca, Ce metrics.

这篇关于依赖性分析工具-更新回归测试用例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆