Directory Image
This website uses cookies to improve user experience. By using our website you consent to all cookies in accordance with our Privacy Policy.

Usage of Selenium WebDriver, Jenkins and Allure for Automation Testing

Author: Info Campus
by Info Campus
Posted: Apr 24, 2017
Before we make a plunge, only a note that to better comprehends whatever is left of this blog entry, you ought to as of now be acquainted with the fundamentals of programming dialects and unit tests.

Keeping in mind the end goal to make computerized testing in a continuous integration (CI) condition, with the goal of making a constant testing (CT) stream, you should acclimate yourself with a progression of robotization and testing devices. In this post, I'll take a gander at how to consolidate and use these instruments to execute and mechanize testing in CI/CD.

There are bunches of devices and procedures that can be incorporated in a CI domain. Here at BlazeMeter, we are utilizing Selenium WebDriver Python and we coordinate it with Jenkins. The testing system we are working with is PyTest, which makes it simple to compose little tests, yet scales to bolster complex utilitarian testing for applications and libraries. Selenium Training in Bangalore.

Before composing your tests and having the capacity to execute them on a daily premise, there are a few requirements which need to mull over.

Set up Your Environment:-

Keeping in mind the end goal to set up your condition for testing, you ought to play out the accompanying strides.

1. Pick your Browser

We will concentrate on ChromeDriver as a proof of idea, however there are other desktop programs accessible out there, for example, FirefoxDriver, InternetExplorerDriver, SafariDriver, OperaDriver and PhantomJS. Download ChromeDriver and store it under the worldwide/canister envelope. For our situation it will be/python27/container.

2. Pick your Programming Language and IDE

We will concentrate on Python since this is the dialect we for the most part use in BlazeMeter, yet you may pick any dialect you crave the length of webdriver has ties to it.

The significant IDE (coordinated advancement condition) for our motivations would be PyCharm. Selenium Courses in Bangalore.

3. Jump into Selenium Web Driver

Selenium WebDriver is one of the main open source devices for computerized testing. As a rule, Webdriver is one of the top GUI testing apparatuses there is. In the event that you haven't caught wind of WebDriver yet, this is your opportunity to profound make a plunge request to use an excellent robotized testing and a steady item.

4. Choose Which Testing Framework You Want

Contingent upon the programming dialect that you have picked, the following stride is pick the testing structure. We will concentrate on Py.Test since this is the trying system we are working with in BlazeMeter.

Obviously, there are numerous other testing systems from which to look over. selenium classes

Make your Tests:-

When you have arranged your condition for robotized tests, simply ahead and make your first End-to-End (E2E) stream. Remember that your tests ought to be as brisk and short as conceivable keeping in mind the end goal to get ready for continuous changes in the code.

Run Your Tests by means of Jenkins:-

As an extensible mechanization server, Jenkins can be utilized as a straightforward CI server or transformed into the persistent conveyance center point for any venture.

It is best to run your tests in a pre-arranged virtual condition which introduces requirements.txt before actualizing them in Jenkins.

  • Make a Virtual Environment
  • Send out Project Requirements
  • Introduce the Allure Reports Plugin to Jenkins

Allure is an open source system intended to make test execution reports with great portrayal of the test execution yield. The Allure Plugin enables you to naturally produce an Allure Report and append it to any form amid a Jenkins work run. Introduce the module and after that we should begin working with Jenkins. Selenium training institutes in Bangalore

Make a New Jenkins Job:-

The Jenkins work you are presently going to make ought to incorporate the majority of the means said above, including:

  • Make virtual condition
  • Introduce requirements.txt
  • Actuate virtual condition
  • Run tests
  • Deactivate virtual condition

See Your Test Results in Allure Reports:-

After effectively coordinating your venture into Jenkins, the following test is to send out the test results to a coherent easy to understand report. Appeal permits to infuse condition variable and to give measurements on tests statuses.

Allure has bunches of cool components and parameters which can be installed into the live report, for example, screenshots, logs records and some more.

About Author:

Selenium Training in Bangalore is provided by Infocampus in which core java is included. Syllabus is designed according to industry standards for both freshers and professionals. Weekend and regular selenium classes are available at INFOCAMPUS. For more information on Selenium Courses in Bangalore, contact 9738001024. Visit http://infocampus.co.in/best-selenium-testing-training-center-in-bangalore.html

About the Author

Infocampus is a training institute that offers training on different technologies. Call 9738001024 for more details. Enquire at http://infocampus.co.in

Rate this Article
Leave a Comment
Author Thumbnail
I Agree:
Comment 
Pictures
Author: Info Campus

Info Campus

Member since: Dec 10, 2016
Published articles: 413

Related Articles