开发者

Is Watir only for Ruby applications?

Or can it be u开发者_如何学Csed to automate websites made with other technologies as well?


Watir is written in Ruby... if you want to write something similar in other languages you can use WatiN(.Net) or Watij(Java). I'm sure there are probably more by now.

In the end... they all can test a web page written in any language.


Ryan is right here, but since this is a common question it should be made even clearer.

WATIR just drives the web browser. The browser does not know or care what language is used to create the website or run the webserver and other back-end pieces.

Watir was created as a vendor neutral 'tool' to be used in classes teaching automation techniques to testers with little to no coding experience. The tool proved so useful it took on a life of it's own and has been developed beyond a mere example into a full fledged tool for driving a browser and doing web test automation. Ruby was chosen as the language as it was felt it is an easy language for testers to learn. (and I happen to agree with that)

So you write the automation code in Ruby. That also makes Watir easy to use with state of the art BDD testing frameworks such as Cucumber, which is also in Ruby. But you can use it to test nearly any website.

I personally test a site that is implemented in .net, and runs on IIS and MS SQL, using a combination of Watir, the Watircraft Framework, and Cucumber.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜