SlideShare a Scribd company logo
WHYs and HOWs of
Automation
Understanding need of test
automation and usage
By Shiva and Nalini
Expectations
What are you hoping to get from this session?
Key
Take
Aways:
❏ Why is Test automation needed.
❏ Different ways and levels of
automation.
❏ Hands on Automation exercise using
Selenium.
Why Automation needed?
Repetitive
Tests.
Larger No of
Boundary Value
Tests
Frequent Code
changes
Continuous
Delivery
Wide
Coverage.
Execution time,
Money and
Accuracy
Automation Myths
❖ Test Automation Costs Too Much
❖ We Have to Replace Manual Testers
❖ All Tests Will Be Automated
❖ Faster Software Release Cycle
❖ Quick ROI
What can be automated
Different Levels of Automation
Implementation
API Layer
Presentation
Layer
Business Layer
Presentation
Layer
Presentation
Layer
HOW?
...things get clearer when you can see them :)
Tech and Tools
Whys and Hows of Automation
Let’s get started with
Selenium
...lets see some examples...
Why Selenium?
● OS independent
● Multiple languages Python, PERL, RUBY, PHP, .NET(C#), Java
● Supports lot many browsers
● Open source and have a good community base
● Robust methods to locate elements
Demo - try it yourself!
Automate a scenario using
Selenium IDE
Scenario: Search an Element
❏Open an URL
❏Search for an element
❏Repeat the test in Selenium IDE
Initiate a Browser through
Selenium
Open application through Firefox and Chrome
Chrome:
System.setProperty("webdriver.chrome.driver", "/<path to chrome driver>/chromedriver");
String url = "http://localhost:3000";
WebDriver driver = new ChromeDriver();
driver.get(url);
Firefox:
System.setProperty("webdriver.gecko.driver","/Users/shivalis/Downloads/geckodriver");
String url = "http://localhost:3000";
WebDriver driver = new FirefoxDriver();
driver.get(url);
Start Interacting with an
application
Scenario: Login to Spree e-Commerce Application
Find By ID
System.setProperty("webdriver.chrome.driver", "/Users/shivalis/Downloads/chromedriver");
String url = "http://localhost:3000";
WebDriver driver = new ChromeDriver();
driver.get(url);
// Find By Id
WebElement login_icon = driver.findElement(By.id("link-to-login"));
login_icon.click();
WebElement user_name = driver.findElement(By.id("spree_user_email"));
By Name and XPath
// Find By Name
WebElement pswd = driver.findElement(By.name("spree_user[password]"));
user_name.sendKeys("xt@xt.com");
pswd.sendKeys("xtxtxt");
// Find By Xpath
WebElement submit_button =
driver.findElement(By.xpath("//*[@id='new_spree_user']/p[2]/input"));
submit_button.submit();
Scenario: Search for an
element and add it to cart
@Test
public void searchForAnElement()
{
System.setProperty("webdriver.chrome.driver", "/Users/shivalis/Downloads/chromedriver");
String url = "http://localhost:3000";
WebDriver driver = new ChromeDriver();
driver.get(url);
// Find By Id
WebElement search_box = driver.findElement(By.id("keywords"));
search_box.sendKeys("Bag");
WebElement search_bar = driver.findElement(By.xpath("//*[@id="search-bar"]/form/input[2]"));
search_bar.click();
// Find multiple elements
List<WebElement> products = driver.findElements(By.xpath("//*[@id="products"]/li"));
System.out.println(products.size());
Assert.assertEquals("Size doesn't match ",2, products.size());
}
Add Assertion to your
Scenario
Closing notes
...time flies when you’re automating tests...
Suggestions
● Automate as you go
● Identify automatable
candidates
● Identify levels to Implement
Automation
● Cross role pairing
Key
Take
Aways:
❏ Why is Test automation needed.
❏ Different ways and levels of
automation.
❏ Hands on Automation exercise using
Selenium.
Questions

More Related Content

PPTX
An approach to app security - For beginners
PPTX
Increase automation to rest
PPTX
Api testing libraries using java script an overview
PDF
Cucumber ppt
PPTX
Test Automation Framework with BDD and Cucumber
PPTX
Brace yourself from automation death trap
PDF
UI Testing Automation
PPTX
Protractor for angularJS
An approach to app security - For beginners
Increase automation to rest
Api testing libraries using java script an overview
Cucumber ppt
Test Automation Framework with BDD and Cucumber
Brace yourself from automation death trap
UI Testing Automation
Protractor for angularJS

What's hot (20)

PPTX
Protractor overview
PDF
Automated Web Testing using JavaScript
PPTX
Automated Testing using JavaScript
PDF
Introduction to Protractor
PDF
Selenium Tips & Tricks
PDF
Web UI test automation instruments
PPTX
Protractor Tutorial Quality in Agile 2015
PDF
Selenium Overview
PPTX
Selenium Design Patterns
PPTX
Better End-to-End Testing with Page Objects Model using Protractor
PDF
Behavior Driven Development and Automation Testing Using Cucumber
PPT
Selenium Architecture
PDF
Cypress - Best Practices
PPTX
Selenium for Jobseekers
PPTX
PPTX
Web automation with Selenium for software engineers
PDF
Carmen Popoviciu - Protractor styleguide | Codemotion Milan 2015
PDF
Practical Tips & Tricks for Selenium Test Automation
PDF
Join the darkside: Selenium testing with Nightwatch.js
PPTX
Automation using Javascript
Protractor overview
Automated Web Testing using JavaScript
Automated Testing using JavaScript
Introduction to Protractor
Selenium Tips & Tricks
Web UI test automation instruments
Protractor Tutorial Quality in Agile 2015
Selenium Overview
Selenium Design Patterns
Better End-to-End Testing with Page Objects Model using Protractor
Behavior Driven Development and Automation Testing Using Cucumber
Selenium Architecture
Cypress - Best Practices
Selenium for Jobseekers
Web automation with Selenium for software engineers
Carmen Popoviciu - Protractor styleguide | Codemotion Milan 2015
Practical Tips & Tricks for Selenium Test Automation
Join the darkside: Selenium testing with Nightwatch.js
Automation using Javascript
Ad

Viewers also liked (20)

PPTX
Test Automation Pyramid
PPTX
Mobile automation using appium.pptx
PPTX
Stand up
PPTX
Test automation Frame Works
PDF
Jumpstarting Testing In Your Organization with Selenium, Cucumber, & WebdriverIO
PDF
Java Faqs useful for freshers and experienced
PDF
S6 the guardian of line today automation test
PDF
Presentation to create awareness in the top management of sport organization ...
PPTX
Katla 1
PPTX
Spotkanie z ambasadorem
PPTX
My favorite sport[1]
PDF
Master Class 'Servicialisation - From Service Identifying to Service Billing ...
PDF
23.05
PPT
Power point 6 media
PPTX
äänenhuoltoa oppaille
PDF
Ashwini - Effective use of CI by QA
DOCX
Abstract 2012 inascl final one page las vegas
PPTX
Nuevas tecnologías en diagnóstico y terapéutica ocular Universidad Técnica de...
PDF
Web ve
Test Automation Pyramid
Mobile automation using appium.pptx
Stand up
Test automation Frame Works
Jumpstarting Testing In Your Organization with Selenium, Cucumber, & WebdriverIO
Java Faqs useful for freshers and experienced
S6 the guardian of line today automation test
Presentation to create awareness in the top management of sport organization ...
Katla 1
Spotkanie z ambasadorem
My favorite sport[1]
Master Class 'Servicialisation - From Service Identifying to Service Billing ...
23.05
Power point 6 media
äänenhuoltoa oppaille
Ashwini - Effective use of CI by QA
Abstract 2012 inascl final one page las vegas
Nuevas tecnologías en diagnóstico y terapéutica ocular Universidad Técnica de...
Web ve
Ad

Similar to Whys and Hows of Automation (20)

PPT
Selenium testing - Handle Elements in WebDriver
PDF
2013 10-10 selenium presentation to ocjug
PPTX
Selenium.pptx
PDF
Dev Dives: Boosting Productivity with Coded Automation and Autopilot™
PPTX
Automated Testing with Google Chrome - WebDriver- ChromeDriver
PPT
Selenium
PDF
Selenium course training institute ameerpet hyderabad – Best software trainin...
PDF
Selenium course training institute ameerpet hyderabad
PPT
Selenium-Webdriver With PHPUnit Automation test for Joomla CMS!
PPTX
Selenium training
PPT
By combining Selenium for frontend testing and tools
PDF
Workshop: Functional testing made easy with PHPUnit & Selenium (phpCE Poland,...
PPT
Selenium
PPT
PPTX
Selenium web driver
PPTX
Introduction to the Selenium_Session1.pptx
PDF
Selenium Tips & Tricks, presented at the Tel Aviv Selenium Meetup
PDF
Testing mit Codeception: Full-stack testing PHP framework
PPTX
Slides for Automation Testing or End to End testing
PPT
Selenium
Selenium testing - Handle Elements in WebDriver
2013 10-10 selenium presentation to ocjug
Selenium.pptx
Dev Dives: Boosting Productivity with Coded Automation and Autopilot™
Automated Testing with Google Chrome - WebDriver- ChromeDriver
Selenium
Selenium course training institute ameerpet hyderabad – Best software trainin...
Selenium course training institute ameerpet hyderabad
Selenium-Webdriver With PHPUnit Automation test for Joomla CMS!
Selenium training
By combining Selenium for frontend testing and tools
Workshop: Functional testing made easy with PHPUnit & Selenium (phpCE Poland,...
Selenium
Selenium web driver
Introduction to the Selenium_Session1.pptx
Selenium Tips & Tricks, presented at the Tel Aviv Selenium Meetup
Testing mit Codeception: Full-stack testing PHP framework
Slides for Automation Testing or End to End testing
Selenium

More from vodQA (20)

PPTX
Performance Testing
PPTX
Testing Strategy in Micro Frontend architecture
PPTX
Testing face authentication on mobile
PPTX
Testing cna
PPTX
Etl engine testing with scala
PPTX
EDA for QAs
PDF
vodQA Pune (2019) - Browser automation using dev tools
PPTX
vodQA Pune (2019) - Augmented reality overview and testing challenges
PPTX
vodQA Pune (2019) - Testing AI,ML applications
PPTX
vodQA Pune (2019) - Design patterns in test automation
PPTX
vodQA Pune (2019) - Testing ethereum smart contracts
PPTX
vodQA Pune (2019) - Insights into big data testing
PDF
vodQA Pune (2019) - Performance testing cloud deployments
PDF
vodQA Pune (2019) - Jenkins pipeline As code
PPTX
vodQA(Pune) 2018 - Consumer driven contract testing using pact
PPTX
vodQA(Pune) 2018 - Visual testing of web apps in headless environment manis...
PPTX
vodQA(Pune) 2018 - Enhancing the capabilities of testing team preparing for...
PPTX
vodQA(Pune) 2018 - QAing the security way
PPTX
vodQA(Pune) 2018 - Docker in Testing
PPTX
Retrospective
Performance Testing
Testing Strategy in Micro Frontend architecture
Testing face authentication on mobile
Testing cna
Etl engine testing with scala
EDA for QAs
vodQA Pune (2019) - Browser automation using dev tools
vodQA Pune (2019) - Augmented reality overview and testing challenges
vodQA Pune (2019) - Testing AI,ML applications
vodQA Pune (2019) - Design patterns in test automation
vodQA Pune (2019) - Testing ethereum smart contracts
vodQA Pune (2019) - Insights into big data testing
vodQA Pune (2019) - Performance testing cloud deployments
vodQA Pune (2019) - Jenkins pipeline As code
vodQA(Pune) 2018 - Consumer driven contract testing using pact
vodQA(Pune) 2018 - Visual testing of web apps in headless environment manis...
vodQA(Pune) 2018 - Enhancing the capabilities of testing team preparing for...
vodQA(Pune) 2018 - QAing the security way
vodQA(Pune) 2018 - Docker in Testing
Retrospective

Recently uploaded (20)

PDF
Modernizing your data center with Dell and AMD
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Approach and Philosophy of On baking technology
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
Big Data Technologies - Introduction.pptx
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Machine learning based COVID-19 study performance prediction
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
A Presentation on Artificial Intelligence
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Electronic commerce courselecture one. Pdf
PDF
NewMind AI Monthly Chronicles - July 2025
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
MYSQL Presentation for SQL database connectivity
Modernizing your data center with Dell and AMD
NewMind AI Weekly Chronicles - August'25 Week I
Building Integrated photovoltaic BIPV_UPV.pdf
Approach and Philosophy of On baking technology
“AI and Expert System Decision Support & Business Intelligence Systems”
Big Data Technologies - Introduction.pptx
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
20250228 LYD VKU AI Blended-Learning.pptx
Machine learning based COVID-19 study performance prediction
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Network Security Unit 5.pdf for BCA BBA.
A Presentation on Artificial Intelligence
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Unlocking AI with Model Context Protocol (MCP)
Electronic commerce courselecture one. Pdf
NewMind AI Monthly Chronicles - July 2025
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
MYSQL Presentation for SQL database connectivity

Whys and Hows of Automation

  • 1. WHYs and HOWs of Automation Understanding need of test automation and usage By Shiva and Nalini
  • 2. Expectations What are you hoping to get from this session?
  • 3. Key Take Aways: ❏ Why is Test automation needed. ❏ Different ways and levels of automation. ❏ Hands on Automation exercise using Selenium.
  • 5. Repetitive Tests. Larger No of Boundary Value Tests Frequent Code changes Continuous Delivery Wide Coverage. Execution time, Money and Accuracy
  • 7. ❖ Test Automation Costs Too Much ❖ We Have to Replace Manual Testers ❖ All Tests Will Be Automated ❖ Faster Software Release Cycle ❖ Quick ROI
  • 8. What can be automated
  • 9. Different Levels of Automation Implementation API Layer Presentation Layer Business Layer Presentation Layer Presentation Layer
  • 10. HOW? ...things get clearer when you can see them :)
  • 13. Let’s get started with Selenium ...lets see some examples...
  • 15. ● OS independent ● Multiple languages Python, PERL, RUBY, PHP, .NET(C#), Java ● Supports lot many browsers ● Open source and have a good community base ● Robust methods to locate elements
  • 16. Demo - try it yourself!
  • 17. Automate a scenario using Selenium IDE
  • 18. Scenario: Search an Element ❏Open an URL ❏Search for an element ❏Repeat the test in Selenium IDE
  • 19. Initiate a Browser through Selenium
  • 20. Open application through Firefox and Chrome Chrome: System.setProperty("webdriver.chrome.driver", "/<path to chrome driver>/chromedriver"); String url = "http://localhost:3000"; WebDriver driver = new ChromeDriver(); driver.get(url); Firefox: System.setProperty("webdriver.gecko.driver","/Users/shivalis/Downloads/geckodriver"); String url = "http://localhost:3000"; WebDriver driver = new FirefoxDriver(); driver.get(url);
  • 21. Start Interacting with an application
  • 22. Scenario: Login to Spree e-Commerce Application Find By ID System.setProperty("webdriver.chrome.driver", "/Users/shivalis/Downloads/chromedriver"); String url = "http://localhost:3000"; WebDriver driver = new ChromeDriver(); driver.get(url); // Find By Id WebElement login_icon = driver.findElement(By.id("link-to-login")); login_icon.click(); WebElement user_name = driver.findElement(By.id("spree_user_email"));
  • 23. By Name and XPath // Find By Name WebElement pswd = driver.findElement(By.name("spree_user[password]")); user_name.sendKeys("xt@xt.com"); pswd.sendKeys("xtxtxt"); // Find By Xpath WebElement submit_button = driver.findElement(By.xpath("//*[@id='new_spree_user']/p[2]/input")); submit_button.submit();
  • 24. Scenario: Search for an element and add it to cart
  • 25. @Test public void searchForAnElement() { System.setProperty("webdriver.chrome.driver", "/Users/shivalis/Downloads/chromedriver"); String url = "http://localhost:3000"; WebDriver driver = new ChromeDriver(); driver.get(url); // Find By Id WebElement search_box = driver.findElement(By.id("keywords")); search_box.sendKeys("Bag"); WebElement search_bar = driver.findElement(By.xpath("//*[@id="search-bar"]/form/input[2]")); search_bar.click(); // Find multiple elements List<WebElement> products = driver.findElements(By.xpath("//*[@id="products"]/li")); System.out.println(products.size()); Assert.assertEquals("Size doesn't match ",2, products.size()); }
  • 26. Add Assertion to your Scenario
  • 27. Closing notes ...time flies when you’re automating tests...
  • 28. Suggestions ● Automate as you go ● Identify automatable candidates ● Identify levels to Implement Automation ● Cross role pairing
  • 29. Key Take Aways: ❏ Why is Test automation needed. ❏ Different ways and levels of automation. ❏ Hands on Automation exercise using Selenium.

Editor's Notes

  • #4: Shiva: What are WebServices; Importance of Web Services Learn How do we test a WebService using different tools and programming libraries Get familiarised with automating WebService.
  • #10: Shiva:
  • #12: Shiva
  • #18: Fiona
  • #20: Shiva
  • #27: Shiva
  • #31: Both