简体   繁体   English

Jenkins UI自动化测试

[英]Jenkins UI Automation testing

We have the following UI as shown in the image. 如图所示,我们具有以下UI。 These parameters are cascaded ie they are inter-dependent. 这些参数是级联的,即它们是相互依赖的。 If you select continent then respective countries will come and then when you select country respective city will come. 如果选择大洲,则将出现相应的国家,然后,当您选择国家时,将出现相应的城市。

在此处输入图片说明

I want to automate testing of each option. 我想自动测试每个选项。 This was just a dummy UI. 这只是一个虚拟的UI。 In my case these fields are dynamic ie generated on the fly through shell/groovy scripts and I have more than 10 such fields. 就我而言,这些字段是动态的,即通过shell / groovy脚本动态生成的,而我有10多个这样的字段。

I have seen Robot Framework and Job-DSL Plugin but I am not able to write test cases for these option selection. 我已经看到了Robot Framework和Job-DSL插件,但是无法为这些选项选择编写测试用例。 Also I have seen some tools which record your steps and generate a test file according to steps performed based on option selected and buttons clicked? 我还看到了一些工具,这些工具可以记录您的步骤并根据基于所选选项和单击的按钮执行的步骤生成测试文件。

Can some one guide me for the optimum tool or platform so as to do Automation testing? 有人可以指导我选择最佳工具或平台来进行自动化测试吗?

It's hard to say what is 'the optimal way' but here's what I would do: 很难说什么是“最佳方法”,但这是我要做的:

I assume that all selections are based on the Jenkins jelly calling a method in your code, I suggest you put the effort in combining these calls in a normal unit test first. 我认为所有选择都是基于Jenkins果冻在您的代码中调用方法的,我建议您先将这些调用合并到正常的单元测试中。 There you can try all possibilities in a much faster way. 您可以在那里以更快的速度尝试所有可能性。

Then when it comes to real UI test, record a Selenium session and translate that into the source code of your choice. 然后,当涉及到真正的UI测试时,记录一个Selenium会话并将其转换为您选择的源代码。

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

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