Creating UI component for my tests - java

I run my test using Java, Selenium and TestNG.
When I execute my test suite I have it set up where the testng.xml has all the configurations to run my tests. I am wondering, if I can set up my own custom UI component that does the same thing as the xml?
I am asking because I have nontechnical people in my staff and I don't want them to have to download an IDE, check out the project, etc. I want to create some UI where they can just go there and hit a button and the tests runs just like how I can right click on the testng.xml and hit run.

You could use a build tool like Jenkins: https://jenkins.io/. This would allow other users to visit a webpage to run the tests instead of using an IDE - as long as they don't need to modify testng.xml.

Related

Scheduling of Automation Tasks Using Jenkins With Selenium Java

I was wondering if I could get some advice regarding automating the scheduling of selenium test cases in java. I have a set of test cases written in Java with selenium and maven that go onto a website, clicks a few buttons which in turn downloads a daily file.
I use AutoItX do interact with the download window to choose my save location and type a name etc.
The code works perfectly for when I execute it normally in Intellij. However I now need to find a process that can kick the build of the code off automatically.
I thought about using Jenkins however it is unable to access my download folder/file system when it comes to downloading files. I also thought about setting a task scheduler on my system to run a batch file that would kick off the project but I cannot guarantee the system will always be on and logged in.
The question I have is: Is there a way to grant jenkins a way to interact with my file system or is there an alternative tool which will allow me to do this.
Or am I missing a config step that will allow me to accomplish what I want?
Thanks in advance.
If you are running Jenkins as a windows service you can allow it to interact with desktop and run it as a user with elevated privileges. e.g.
You can schedule Jenkins job that will be triggered at certain intervals. e.g. you may want to run it at 9PM then Build periodically is the option you may want to use.

Develop a web application for running test cases

I want to develop a web application which takes github url(containing TestNG test cases written in Java and selenium) and TestNg.xml name as input. if we click on Run button, it should take the code from Github and then run the test cases present in it in the backend and display the result on the UI. Please suggest me ,How should I proceed developing such application ?

I want to Add my Automation framework created using selenium into JMeter

I want add my automation framework in JMeter to perform load and performance testing. I have created Jar file of the project but I don't know how to proceed further to perform load testing. Please assist me with this or any other suggestions.
The easiest way to create the load test from your Selenium test suite is just recording it via JMeter's HTTP(S) Test Script Recorder
Configure JMeter for recording.
From main menu choose File -> Templates -> Recording -> Create
Expand Workbench -> HTTP(S) Test Script Recorder and click "Start"
Configure Selenium tests to use JMeter as a proxy
Run your Selenium tests (you can observe recorded requests under Test Plan -> Recording Controller)
Perform correlation if required
Add virtual users
There is an alternative solution which will allow you to avoid step 4, check out How to Convert Selenium Scripts into the JMX Converter for details.

Is there a way to manually export testng test results from a function and not clicking the button?

I am working in with Java in intelliJ and have a testSuite that I would eventually like to be able to automatically run, export test results to file, and email those results to my boss. The test runs and the e-mail sends with the attachment. I just can't seem to figure out if there is a certain method that I can implement to do such a thing.
You can achieve this by installing a continuous integration server, which will monitor your version control system, run the tests every time you commit code, and send the notifications according to your configuration (for example, by sending an email to your boss if that's what you need).
Popular continuous integration servers include Jenkins and TeamCity.

Need to run complete test suite in Junit/TestNG from web page kind of tool

I have few test cases written in testNG and Junit using selenium for testing a webpage. But for executing them i need to go to command line or run them using eclipse each time i want to run. I want a centralised web page from where i can select what test i want to run and just click on some button to say run. And can see the output results on the same page. How could i achieve that?
Thanks-
Girish.
We use Jenkins in our project to do this kind of simplification when we want our business users to trigger tests. However, it may initially take some setup for each set of tests you want to run.

Categories

Resources