JSF:AJAX 测试最佳实践
我们有一个大量使用 AJAX 的 JSF 2.0 项目(由 OpenFaces 标签库提供)。我们的项目非常酷,做了很多有用的事情,我们喜欢它。然而,有一件事让我们感到沮丧——我们的项目没有集成测试。完全没有。当然它有硒测试,但它们仅从用户的角度覆盖该项目。我想要的是一些处理 AJAX 相关逻辑的集成测试。但我不知道如何实现这一点...引起我注意的是 JSFUnit 和 HTTPUnit,但我想知道是否有更好的基于 AJAX 的 JSF 项目。有人对此有任何顾虑吗? 谢谢!
We have a JSF 2.0 project with heavy use of AJAX (provided by OpenFaces tag library). Our project is very cool and does many useful things, and we love it. However there is one thing about it that frustrates us - our project doesn't have integration tests. At all. It has selenium tests of course, but they cover the project only from user's perspective. What I'd love to have are some integration tests which would deal with AJAX-related logic. But I'm not sure how to achieve this... Things that are capturing my mind are JSFUnit and HTTPUnit, but I wonder if there is something better for AJAX-based JSF project. Does anyone have any concerns about this?
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以尝试 FireUnit 或 FireBugTest。我没有尝试过其中任何一个,但它们可能会起作用。我也一直希望有这样的功能。
You could try FireUnit or FireBugTest. I haven't tried either of these but they might work. I have always wished for a feature like this too.
你试过瓦蒂尔吗
http://wiki.openqa.org/display/WTR/Simple+Ajax+examples
它还有一个 Firefox 变体。 FireWatir——
基兰·库马尔
have you tried Watir
http://wiki.openqa.org/display/WTR/Simple+Ajax+examples
It also has a firefox variant. FireWatir
--Kiran.Kumar