What is the Best Way to learn SELENIUM?



I continuously see newbie questions like: "How I do I learn Selenium?", with little or no other context given.

So first... a clarification:
Selenium WebDriver is a system for automating browser interaction. It is accessed via programming library/API. If you want to use it without touching code, it is not possible (record/replay/export-madness via IDE aside). You can abstract away most of the programming aspects with higher level frameworks, but at that point you are no longer really dealing with Selenium anymore.

Selenium (WebDriver) provides language bindings and a similar API for several programming languages. It gives you a programming library that can manipulate a browser and web elements/controls.
You can't "learn" a library for a programming language if you don't know the language itself (syntax, idioms, etc).

So, my question to you: Which programming language are you going to use Selenium with? If you define that, someone can surely help point you in the right direction.

How are your programming skills? Which language do you want to learn in? If you know several, switching is trivial down the line, as the API's are similar between languages.

If you don't have skills in any Selenium supported programming language (java, c#, python, ruby, php, etc), then learn one of those before you even touch Selenium.

Selenium is a very small piece and once you know any of the programming languages well, you will find that its just like any other automation tool

Focus on JAVA(if that's your preferred choice of language ):

  1. OOPS : Encapsulation, Abstraction, Polymorphism, Inheritance.
  2. Introduction to class, Instance Variables, Instance methods, Class Variables, Class methods, Object.
  3. Constructors, Abstract methods, Abstract class, Interface (Multiple inheritance), Method overloading, Method Overriding, Packages.You definitely know when to create a class or Interface, how to initialize your instance variables(Non static).
  4. Control Statements:To be able to make decisions in test methods, Should I continue test execution,If login fails.
  5. Loops : Login into 5 different account using same methods.
  6. Arrays: No need to write variables all over test scrips.
  7. Exception Handling : How to continue with test execution if something unexpected happens during the test execution.
  8. Files and Streams: In case u want to keep test data out of your java source file,but how would u access them in your test scripts.( Parameterisation in Selenium)
  9. Collection framework.
  10. Multi-threading.

Happy Learning !

Comments

Post a Comment

Popular posts from this blog

Explain public static void main in Java

Reserve or Key Words in Java

OOPs concepts in Java with Examples