Tuesday, 9 May 2017

Selenium WebDriver Without Maven

Selenium WebDriver is a software testing tool as I described it in my previous posts. It provides customize way to do software testing.

There are mainly two ways to start with Selenium

1)  Without Maven
2)  With Maven (Professionals way)

We will discuss 'Maven' in next post

Prerequisite before start with selenium

1) Eclipse IDE link to download Eclipse

2) Install Java JDK How to setup java

3) Download Selenium Webdriver (Described below)

Without Maven

1) Create java project
    New  --> other --> Java Project


2) Give your project a name. I've' named it "seleniumdemo" and className "SeleniumWithoutMaven"
     src --> New --> Class

3) Your project structure should look like below image


4) Dowload selenium server from Link

   seleniumhq.png


5) Download chrome driver Link

chromedrive.png


6) Now configure Build Path
Project→ Build Path → Configure Build Path

configurebuildpath.png


7) Add External Jar “Selenium Server” through configure Build Path

configurebuildpathwindow.png


8) After adding verify jar presence

verify jar presence.png


9) Add below mention code(Imp Mention chrome Driver Path)
System.setProperty("webdriver.chrome.driver", "Chrome_driver_Path");
WebDriver driver = new ChromeDriver();
driver.get("http://www.seleniumhq.org");
System.out.println("Chrome Browser Launch Selenium Site");


seleniumcode.png


10) Run (Ctrl+F11) / “Run as Java Application”

runasjavaaaplication.png


Next Post on Selenium WebDriver With Maven (Professionals way) 

Leave comments if you still face challenges
 

Monday, 1 May 2017

How to install and setup Java


1) Download java JDK. link to download


















2) Select Java jdk as per your system configuration




3) After that you will get an '.exe' file install it

4)After installation




5) Here you can see the java "C:\Program Files\Java"

6)Create a 'JAVA_HOME' Environment variable 



7) In 'Path' Environment variabe add '%JAVA_HOME%\bin' 



8) After OK, You are done with the setup.

9) To verify open 'command prompt' (To access 'cmd' follow below process)
(Win+R), Enter 'cmd' in run and then Enter'

10) Write 'javac' on cmd and then you can see some stracktrace


11) Now you are done

Comment me if you face any challenges during this process

Labels: , , , , , ,

Selenium IDE

Selenium IDE is the simplest tool to use. It is a Firefox plugin which record user actions and then play when needed.


How to use:-


  1. Go to http://www.seleniumhq.org/download/ and then under under Selenium IDE portion  click  on from addons.mozilla.org

    seleniumhq.png
Clicked on ‘Add to Firefox’

addtofirefox.png

3) Clicked ‘Se’ icon to access Selenium IDE

ideaccess.png

4) Selenium IDE tool

readyide.png

5) For using this tool please refer http://www.guru99.com/introduction-selenuim-ide.html Believe me its too simple to use it. If still faces challenges comment me

Next blog on Selenium WebDriver

Labels: , , , ,

About Selenium

Not including the part of Selenium history and so on. Start with basic knowledge

Selenium Mainly has 4 parts

1) Selenium IDE
2) Selenium Grid
3) Selenium WebDriver
4) Selenium RC

Selenium IDE:-

 Selenium IDE is a simplest part of selenium. It is a Firefox plugin which records user actions on browser and play it later like QTP. No prior programming language needed for using it.

Selenium Grid:-

Selenium Grid provides the facility to execute your tests parallel on different machines. Eaisest way to test your tests on different browsers with different system configurations.

Selenium WebDriver:-

Selenium WebDriver supports multiple browsers along with many OS.Provide customize way to perform actions on browser along with different tools integrations. The most famous and usable part of Selenium Suite

Selenium RC:-
It's now deprecated

Next blog on "Selenium IDE" 

Labels: , , , ,