简体   繁体   English

如何处理硒中的不同语言?

[英]How to handle different language in selenium?

My application is supporting two languages, namely English and French and my single Test case supports both languages.我的应用程序支持两种语言,即英语和法语,我的单个测试用例支持两种语言。 Then phase1 is able to run the Test case in English as well as in French.然后 phase1 能够以英语和法语运行测试用例。 So what will be the basic structure of the framework to fullfill this requirement?那么满足这个要求的框架的基本结构是什么?

Selenium could support most languages. Selenium 可以支持大多数语言。 The only difference is that when You want to check page content You should use selectors without text search(so no search by text, linkText etc., which sometimes is problematic).唯一的区别是,当你想检查页面内容时,你应该使用没有文本搜索的选择器(所以不能通过文本、链接文本等进行搜索,这有时是有问题的)。 So basic logic should be the same.所以基本逻辑应该是一样的。 Only when some pages are language specifit that could be specific test scripts.只有当某些页面是特定语言时,才可能是特定的测试脚本。

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

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