SlideShare a Scribd company logo
Web Application Testing
Ynon Perek	

ynon@ynonperek.com	

http://ynonperek.com
Agenda
• Developing for the web. Why is it hard?	

• What can you test?	

• Testing architecture
Why is it hard?
Why is it hard?
• Many different browsers	

• Many different devices
Automatic testing is
your only way out …
Imagine …
• Short feedback loop on changes	

• Reduce human mistakes	

• TDD
Types of Tests
Unit tests

http://johnny.github.io/jquery-sortable/

System tests
Unit Tests
• During development, for the developer	

• Instant feedback	

• Future aware	

• Easy to maintain
System Tests
• Tests entire system	

• For the client	

• Easy to write
What Can You Test?
• Everything …	

• But you probably shouldn’t
What Should You Test?
• Past bugs	

• Intended behaviour	

• Edge cases
Testing Architecture
Selen

ium

Chutzpa
Ka
rm

a

js-test-driver
Jenkins

Istan

bul

QUnit

ha
oc
M

Jasmine

TeamCity
Casp

erJS

Travis

PhantomJS
Testing Architecture
style.css

main.js
index.html

car.js
race.js
Testing Architecture
style.css

main.js
index.html

car.js
race.js
Testing Architecture
style.css

main.js
index.html

mocha.js

car.js

test.html

race.js

car_test.js
Testing Architecture
Blanket

Chutzpa

Jasmine

TeamCity

Istanbul

Karma

Mocha

Jenkins

JSCoverage

js-test-driver QUnit

Selenium

CasperJS

Travis
Unit Testing Framework
• Provides structure to test code	

• Easy to report failures	

• Written in JavaScript
Unit Testing Framework
describe('Array', function(){
describe('#indexOf()', function(){
it('should return -1 when not present', function(){
[1,2,3].indexOf(5).should.equal(-1);
[1,2,3].indexOf(0).should.equal(-1);
})
})
})
Unit Test Report
Available Frameworks
• Mocha	

• Jasmine	

• QUnit	

•

http://en.wikipedia.org/wiki/
List_of_unit_testing_frameworks#JavaScript
System Testing Tools
• Control an automatic browser	

• Can use any programming language
System Testing
require "selenium-webdriver"
!
driver = Selenium::WebDriver.for :firefox
driver.navigate.to "http://duckduckgo.com"
!
element = driver.find_element(:name, 'q')
element.send_keys "Hello WebDriver!"
element.submit
!
puts driver.title
!
driver.quit
System Testing Tool
• We’ll use selenium	

• It’s stable and flexible	

• Really easy to automate
Test Runners
• Run tests, report errors	

• Used from command line or IDE	

• Available options:	

• Karma, Chutzpa, js-test-driver
Continuous Integration
• Checkout latest from source control	

• Run all tests	

• Report failures
Continuous Integration
• Travis	

• Jenkins	

• TeamCity
Code Coverage
• % of the code being tested	

• 70-80% is good	

• Istanbul is the tool
Coverage Report
Balancing Tests
• Few system / scenario tests	

• Many unit tests
Resources
• Chuzpa screencast for VS2012:


http://www.youtube.com/watch?
v=meJ94rAN7P8	


• Miško Hevery on Unit Tests (google tech
talks):

http://www.youtube.com/watch?
v=wEhu57pih5w
What Next
• Write unit tests	

• Write functional tests	

• Deploy a CI	

• Set up coverage and test reports
Ready? Let’s Go!
• Ynon Perek	

• http://ynonperek.com	

• ynon@ynonperek.com

More Related Content

What's hot (20)

PDF
Better Page Object Handling with Loadable Component Pattern
Sargis Sargsyan
 
PDF
Test automation & Seleniun by oren rubin
Oren Rubin
 
PPTX
An Introduction to AngularJS End to End Testing using Protractor
Cubet Techno Labs
 
PPTX
Test automation expert days
Oren Rubin
 
PPTX
Protractor training
Sergiy Stotskiy
 
PPTX
Angular UI Testing with Protractor
Andrew Eisenberg
 
PDF
Statistical Element Locator by Oren Rubin - SeleniumConf UK 2016
Oren Rubin
 
PDF
AngularJS and Protractor
Filipe Falcão
 
PPTX
Better End-to-End Testing with Page Objects Model using Protractor
Kasun Kodagoda
 
PDF
Getting By Without "QA"
Dave King
 
PDF
UI Testing Best Practices - An Expected Journey
Oren Farhi
 
PDF
Using The Page Object Pattern
Dante Briones
 
PPTX
Automate testing with behat, selenium, phantom js and nightwatch.js (5)
Faichi Solutions
 
PDF
Automation Abstraction Layers: Page Objects and Beyond
Alan Richardson
 
PPTX
Protractor survival guide
László Andrási
 
PDF
Testing Code.org's Interactive CS Curriculum
Brian Jordan
 
PPTX
Nightwatch JS for End to End Tests
Sriram Angajala
 
PDF
How To Use Selenium Successfully
Dave Haeffner
 
PDF
Testing mit Codeception: Full-stack testing PHP framework
SusannSgorzaly
 
PPTX
Marcin Wasilczyk - Page objects with selenium
Trójmiejska Grupa Testerska
 
Better Page Object Handling with Loadable Component Pattern
Sargis Sargsyan
 
Test automation & Seleniun by oren rubin
Oren Rubin
 
An Introduction to AngularJS End to End Testing using Protractor
Cubet Techno Labs
 
Test automation expert days
Oren Rubin
 
Protractor training
Sergiy Stotskiy
 
Angular UI Testing with Protractor
Andrew Eisenberg
 
Statistical Element Locator by Oren Rubin - SeleniumConf UK 2016
Oren Rubin
 
AngularJS and Protractor
Filipe Falcão
 
Better End-to-End Testing with Page Objects Model using Protractor
Kasun Kodagoda
 
Getting By Without "QA"
Dave King
 
UI Testing Best Practices - An Expected Journey
Oren Farhi
 
Using The Page Object Pattern
Dante Briones
 
Automate testing with behat, selenium, phantom js and nightwatch.js (5)
Faichi Solutions
 
Automation Abstraction Layers: Page Objects and Beyond
Alan Richardson
 
Protractor survival guide
László Andrási
 
Testing Code.org's Interactive CS Curriculum
Brian Jordan
 
Nightwatch JS for End to End Tests
Sriram Angajala
 
How To Use Selenium Successfully
Dave Haeffner
 
Testing mit Codeception: Full-stack testing PHP framework
SusannSgorzaly
 
Marcin Wasilczyk - Page objects with selenium
Trójmiejska Grupa Testerska
 

Viewers also liked (20)

PDF
Web App Testing - A Practical Approach
Walter Mamed
 
PDF
Testing Web Applications
Seth McLaughlin
 
PPTX
Web Application Testing
Richa Goel
 
KEY
Web App Development With YUI 3
Eric Ferraiuolo
 
PPTX
Simplify and Accelerate App Development with Adobe AEM Mobile
Perficient, Inc.
 
PPTX
PAVE
Mike Wilhelm
 
PPTX
Web Application Development Process presented by @Cygnismedia
Clark Davidson
 
PDF
How to write Testable Javascript
ColdFusionConference
 
ZIP
Automated Frontend Testing
Neil Crosby
 
PPTX
Varshneya samdarshi lmu_symposium_2016
GRNsight
 
PDF
How do I write Testable Javascript - Presented at dev.Objective() June 16, 2016
Gavin Pickin
 
PDF
Javascript Unit Testing Tools
PixelCrayons
 
PPTX
Web based automation testing on Node.js environment
Yu-Lin Huang
 
PPT
Test Automation With Cucumber JVM, Selenium, and Mocha
Salesforce Developers
 
PPTX
An Introduction to Unit Testing
Joe Tremblay
 
PDF
Outside In - Behaviour Driven Development (BDD)
Naresh Jain
 
ODP
Custom Android App Development – Web Animation India
Marion Welch
 
PDF
Fullstack End-to-end test automation with Node.js, one year later
Mek Srunyu Stittri
 
PPTX
Testing web application
jayashreesaravanan
 
PDF
Node.js and Selenium Webdriver, a journey from the Java side
Mek Srunyu Stittri
 
Web App Testing - A Practical Approach
Walter Mamed
 
Testing Web Applications
Seth McLaughlin
 
Web Application Testing
Richa Goel
 
Web App Development With YUI 3
Eric Ferraiuolo
 
Simplify and Accelerate App Development with Adobe AEM Mobile
Perficient, Inc.
 
Web Application Development Process presented by @Cygnismedia
Clark Davidson
 
How to write Testable Javascript
ColdFusionConference
 
Automated Frontend Testing
Neil Crosby
 
Varshneya samdarshi lmu_symposium_2016
GRNsight
 
How do I write Testable Javascript - Presented at dev.Objective() June 16, 2016
Gavin Pickin
 
Javascript Unit Testing Tools
PixelCrayons
 
Web based automation testing on Node.js environment
Yu-Lin Huang
 
Test Automation With Cucumber JVM, Selenium, and Mocha
Salesforce Developers
 
An Introduction to Unit Testing
Joe Tremblay
 
Outside In - Behaviour Driven Development (BDD)
Naresh Jain
 
Custom Android App Development – Web Animation India
Marion Welch
 
Fullstack End-to-end test automation with Node.js, one year later
Mek Srunyu Stittri
 
Testing web application
jayashreesaravanan
 
Node.js and Selenium Webdriver, a journey from the Java side
Mek Srunyu Stittri
 
Ad

Similar to Introduction To Web Application Testing (20)

PPTX
Automated Testing using JavaScript
Simon Guest
 
PDF
Automated Web Testing using JavaScript
Simon Guest
 
PDF
3 WAYS TO TEST YOUR COLDFUSION API
Gavin Pickin
 
PDF
3 WAYS TO TEST YOUR COLDFUSION API -
Ortus Solutions, Corp
 
PPTX
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
Ortus Solutions, Corp
 
ODP
Dot Net Notts Js Unit Testing at Microlise
Jonathan Gregory
 
ODP
Js unit testingpresentation
Jonathan Gregory
 
PDF
Frontend automation and stability
Máté Nádasdi
 
PDF
Web Application Testing – The Basics of Web App Test Automation.pdf
pCloudy
 
PDF
Quick tour to front end unit testing using jasmine
Gil Fink
 
PPTX
Java script unit testing
Mats Bryntse
 
PDF
JavaScript TDD with Jasmine and Karma
Christopher Bartling
 
PPTX
4&5.pptx SOFTWARE TESTING UNIT-4 AND UNIT-5
hemasubbu08
 
PPTX
Designing Self-maintaining UI Tests for Web Applications
TechWell
 
PPTX
Automation Testing.pptx
Ankit275957
 
ODP
Unit Testing and Coverage for AngularJS
Knoldus Inc.
 
PDF
A Test Automation Platform Designed for the Future
Applitools
 
PDF
Web Application Testing with Selenium
Sargis Sargsyan
 
PDF
Proven Approaches to AI-Powered E2E Testing.pdf
Applitools
 
PPTX
How selenium can transform your qa career
Shama Ugale
 
Automated Testing using JavaScript
Simon Guest
 
Automated Web Testing using JavaScript
Simon Guest
 
3 WAYS TO TEST YOUR COLDFUSION API
Gavin Pickin
 
3 WAYS TO TEST YOUR COLDFUSION API -
Ortus Solutions, Corp
 
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
Ortus Solutions, Corp
 
Dot Net Notts Js Unit Testing at Microlise
Jonathan Gregory
 
Js unit testingpresentation
Jonathan Gregory
 
Frontend automation and stability
Máté Nádasdi
 
Web Application Testing – The Basics of Web App Test Automation.pdf
pCloudy
 
Quick tour to front end unit testing using jasmine
Gil Fink
 
Java script unit testing
Mats Bryntse
 
JavaScript TDD with Jasmine and Karma
Christopher Bartling
 
4&5.pptx SOFTWARE TESTING UNIT-4 AND UNIT-5
hemasubbu08
 
Designing Self-maintaining UI Tests for Web Applications
TechWell
 
Automation Testing.pptx
Ankit275957
 
Unit Testing and Coverage for AngularJS
Knoldus Inc.
 
A Test Automation Platform Designed for the Future
Applitools
 
Web Application Testing with Selenium
Sargis Sargsyan
 
Proven Approaches to AI-Powered E2E Testing.pdf
Applitools
 
How selenium can transform your qa career
Shama Ugale
 
Ad

More from Ynon Perek (20)

PDF
Regexp
Ynon Perek
 
PDF
Html5 intro
Ynon Perek
 
PDF
09 performance
Ynon Perek
 
PDF
Mobile Web Intro
Ynon Perek
 
PDF
Qt multi threads
Ynon Perek
 
PDF
Vimperl
Ynon Perek
 
PDF
Syllabus
Ynon Perek
 
PDF
Mobile Devices
Ynon Perek
 
PDF
Network
Ynon Perek
 
PDF
Architecture app
Ynon Perek
 
PDF
Cryptography
Ynon Perek
 
PDF
Unit Testing JavaScript Applications
Ynon Perek
 
PDF
How to write easy-to-test JavaScript
Ynon Perek
 
PDF
Introduction to Selenium and Ruby
Ynon Perek
 
PDF
Accessibility
Ynon Perek
 
PDF
Angularjs
Ynon Perek
 
PDF
Js memory
Ynon Perek
 
PDF
Qt Design Patterns
Ynon Perek
 
PDF
Web Application Security
Ynon Perek
 
PDF
JavaScript DOM Manipulations
Ynon Perek
 
Regexp
Ynon Perek
 
Html5 intro
Ynon Perek
 
09 performance
Ynon Perek
 
Mobile Web Intro
Ynon Perek
 
Qt multi threads
Ynon Perek
 
Vimperl
Ynon Perek
 
Syllabus
Ynon Perek
 
Mobile Devices
Ynon Perek
 
Network
Ynon Perek
 
Architecture app
Ynon Perek
 
Cryptography
Ynon Perek
 
Unit Testing JavaScript Applications
Ynon Perek
 
How to write easy-to-test JavaScript
Ynon Perek
 
Introduction to Selenium and Ruby
Ynon Perek
 
Accessibility
Ynon Perek
 
Angularjs
Ynon Perek
 
Js memory
Ynon Perek
 
Qt Design Patterns
Ynon Perek
 
Web Application Security
Ynon Perek
 
JavaScript DOM Manipulations
Ynon Perek
 

Recently uploaded (20)

PDF
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
PPTX
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
PDF
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
PDF
“Squinting Vision Pipelines: Detecting and Correcting Errors in Vision Models...
Edge AI and Vision Alliance
 
PDF
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
PDF
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
PDF
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
PDF
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
DOCX
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
PPTX
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
PPTX
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
PPTX
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
PDF
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
PDF
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
PDF
Mastering Financial Management in Direct Selling
Epixel MLM Software
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PPT
Ericsson LTE presentation SEMINAR 2010.ppt
npat3
 
PDF
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
PDF
Kit-Works Team Study_20250627_한달만에만든사내서비스키링(양다윗).pdf
Wonjun Hwang
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
“Squinting Vision Pipelines: Detecting and Correcting Errors in Vision Models...
Edge AI and Vision Alliance
 
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
Mastering Financial Management in Direct Selling
Epixel MLM Software
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
Ericsson LTE presentation SEMINAR 2010.ppt
npat3
 
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
Kit-Works Team Study_20250627_한달만에만든사내서비스키링(양다윗).pdf
Wonjun Hwang
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 

Introduction To Web Application Testing