Introduction to Selenium 1) What is Selenium? 2) History of the Selenium Project 3) Selenium's Tools Suite Selenium IDE Selenium RC Selenium WebDriver Selenium Grid - 1) What is Selenium?. Selenium is a suite of software tools to automate Web Browsers.
It is an Open source suite of tools mainly used for Functional and Regression Test Automation. Selenium supports various Operating environments. MS Windows Linux Macintosh etc. Selenium supports various Browsers. Mozilla Firefox IE Google Chrome Safari Opera etc. Note: Selenium IDE supports Mozilla Firefox only. Selenium supports various programming environments to write programs (Test scripts) Java C# Python Perl Ruby PHP - 2) History of the Selenium Project.
Selenium first came to life in 2004. In 2006, Selenium WebDriver was launched at Google. In 2008, the whole Selenium team decided to merge Selenium WebDriver with Selenium RC in order to form more powerful tool called Selenium 2.0 Selenium 1 (Selenium IDE + Selenium RC + Selenium Grid) Selenium 2 (Selenium IDE + Selenium RC + Selenium WebDriver + Selenium Grid) - 3) Selenium's Tools Suite i) Selenium IDE It is a Firefox browser plug in, used to create and execute Test cases. Selenium IDE Features:. Create Test Cases, Test suites (We can Record test cases or type Test steps using element locators and Selenese commands). Edit Test Cases.
Execute Test cases, Test suites. Debug Test Cases. Enhance Test Cases. Export Test cases to other formats (java, ruby etc.) Note: selenium IDE Test case default format is.html - Drawbacks of Selenium IDE.
It supports Mozilla Firefox browser only. It doesn't support Programming logic/features to enhance Test cases. It doesn't support Data Driven Testing. It is not suitable for complex test case design. No centralized maintenance of Objects/Elements - ii) Selenium RC (. Out dated) iii) Selenium WebDriver. It is a Programming interface to create and execute Test cases.
Selenium IDE has IDE but doesn't have Programming interface Selenium WebDriver has Programming interface but doesn't have IDE UFT/QTP has both IDE as well as Programming interface -. Selenium WebDriver supports various programming environments to write programs. Java, C# Perl Python Ruby PHP. Using Element/Object locators/properties and Webdriver Methods we can create and execute Test cases. Selenium Webdriver supports various browsers to create and execute test case/test script/test Note: Browser driver varies from one browser to another. Selenium WebDriver supports various operating environments MS Windows Linux Macintosh etc. Drawback of Selenium WebDriver.
It doesn't generate detailed Test Reports. No centralized maintenance of Object/elements - iv) Selenium Grid. Selenium Grid is used to execute tests across multiple browsers, operating environments and machines in parallel. Selenium Grid 2 supports Selenium RC Tests as well as Selenium WebDriver Tests.
Focus on: - i) Selenium WebDriver to create Test cases using element locators and Webdriver methods. Ii) Java Programming to enhance test cases. Iii) TestNG Framework to group test cases, execute test batches and generate detailed test reports.
What is Bug/Defect? Simple Wikipedia definition of Bug is: “A computer bug is an error, flaw, mistake, failure, or fault in a computer program that prevents it from working correctly or produces an incorrect result. Bugs arise from mistakes and errors made by people, in either a program’s source code or its design.” Other definitions can be: An unwanted and unintended property of a program or piece of hardware, especially one that causes it to malfunction. Or A fault in a program, which causes the program to perform in an unintended or unanticipated manner. Lastly, the general definition of a bug is: “failure to conform to specifications”. If you want to detect and resolve the defect in early development stage, defect tracking and software development phases should start simultaneously. We have discussed more on Writing effective in another article.
Let’s concentrate here on bug/defect life cycle. The life cycle of Bug: 1) Log new defect The mandatory fields when a tester logs any new bug are Build version, Submit On, Product, Module, Severity, Synopsis and Description to Reproduce In above list, you can add some optional fields if you are using manual Bug submission template.
These Optional Fields include Customer name, Browser, Operating system, File Attachments or screenshots. The following fields remain either specified or blank: If you have authority to add bug Status, Priority and ‘Assigned to’ fields then you can specify these fields. Otherwise, Test manager will set status, Bug priority and assign the bug to the respective module owner. Look at the following Bug life cycle.
On successful logging, the bug is reviewed by Development or Test manager. Test manager can set the bug status as Open, can Assign the bug to developer or bug may be deferred until next release.
When a bug gets assigned to a developer and he/she can start working on it. The developer can set bug status as won’t fix, Couldn’t reproduce, Need more information or ‘Fixed’. If the bug status set by the developer is either ‘Need more info’ or Fixed then the QA responds with a specific action.
If the bug is fixed then QA verifies the bug and can set the bug status as verified closed or Reopen. Bug status description: These are various stages of bug life cycle.
The status caption may vary depending upon the bug tracking system you are using. 1) New: When QA files a new bug. 2) Deferred: If the bug is not related to a current build or cannot be fixed in this release or bug is not important to fix immediately then the project manager can set the bug status as deferred. 3) Assigned: ‘Assigned to’ field is set by a project lead or manager and the bug is assigned to a developer. 4) Resolved/Fixed: When a developer makes necessary code changes and verifies the changes then he/she can make bug status as ‘Fixed’ and then the bug is passed to the testing team. 5) Could not reproduce: If a developer is not able to reproduce the bug by the steps given in bug report by QA then the developer can mark the bug as ‘CNR’.
QA needs action to check if the bug is reproduced and can assign it to a developer with detailed reproducing steps. 6) Need more information: If a developer is not clear about the bug reproduce steps provided by QA to reproduce the bug, then he/she can mark it as “ Need more information‘.
In this case, QA needs to add detailed reproducing steps and assign bug back to dev for the fix. 7) Reopen: If QA is not satisfied with the fix and if the bug is still reproducible even after fix then QA can mark it as ‘Reopen’ so that developers can take appropriate action. 8 ) Closed: If the bug is verified by the QA team and if the fix is ok and the problem is solved then QA can mark the bug as ‘Closed’. 9) Rejected/Invalid: Sometimes the developer or team lead can mark the bug as Rejected or invalid if the system is working according to specifications and bug is just due to some misinterpretation. Let us know your valuable suggestions/comments on this article. 189 comments ↓ Sheetal Can you please provide any template for bug report? Sailasri Can provide the list of free automation tools and their links to download Sam Can you please provide Real time questions&Answers?
Sam Can you please provide Real time questions&Answers? What is Webapp and Desktop app &windows app? Naveen Pathak Nice defination, but these all state can applied in a manual template, not in a generic tool like, Zera/BugZilla. Trupti can u pls post the real bug report?? Say for login screen.?