SlideShare une entreprise Scribd logo
1  sur  42
Télécharger pour lire hors ligne
3W1H
Jay Chung(xJkit)
What the hell is software testing?
Who am I
Jay Chung (xJkit)
JavaScript developer
Love Everything done by .js and .jsx
GitHub: https://github.com/xJkit
3W1H
Why
Who
What
How
Why Test?
UI/UX
Security (Penetration Test)
Boundary Case
Stress Test
Performance Test
…
White Box
( )
Code Coverage(statement, branch, function, …)
Black Box
spec
Unit Test
Integration Test
System Test
E2E test, Functional test
Acceptance Test
TDD (Test-Driven Development)
BDD (Behaviour-Driven Development)
ATDD (Acceptance TDD)
SBE (Spec by Example)
TDD BDD ATDD
TDD
Red-Green-Refactor Cycle
Red Green Refactor Cycle
TDD
Make a test case fail
Make the code work
Make the code clean
BDD
2003 Dan North
QA
BDD
Scenarios
Behaviour
Scenario: Some determinable business situation
Given some precondition
And some other precondition
When some action by the actor
And some other action
And yet another action
Then some testable outcome is achieved
And something else we can check happens too
ATDD
TDDDiscuss
Distill
Develop
Demo
from user story -> business value
user stories
acceptance
criteria
continuous
integration/delivery
new features
Why ATDD?
http://www.marcofolio.net/other/atdd_is_awesome_and_you_should_try_it.html
V-Model
Requirements
Functional Specification
High-level Design
Low-Level Design
Coding
Unit Test
Integration Test
System Test
Acceptance Test
Project Manager
Verification Validation
TDD -> BDD
Where to start
What to test and what not to test
How much to test in one go
What to call their tests
How to understand why a test fails
Unit Test
white box testing
mocked input -> f(x) -> expected output
for a chunk of codes
from programmer perspective
code coverage reporting
Integration Test
from user’s perspective
ensure the system is functioning as expected
Integration Test is functional test, but not vice
versa
Functional Test
black box test
includes E2E test, Acceptance test, browser
automations
browser/browser-like env
cross browser compatibilities
Just say no to more E2E tests
70%
20%
10%
https://testing.googleblog.com/2015/04/just-say-no-to-more-end-to-end-tests.html
Google
How
This is just a Javascript developer speaking
Mocha
Chai assertion
library
describe ( testing suite)
it ( testing case)
describe/it
Mocha
Jasmine
assertion
mocks, spies,
stubs
Jest
Facebook , Jasmine
Mocha
assertion
snapshots (
)
code coverage reports
mocks, spies, stubs
AVA
Futuristic JavaScript test
runner
concurrency
(run in parallel),
snapshot
Istanbul
Code coverage reporters
Codecov
coverage report + GitHub , travis ci
Chrome GitHub code coverage
https://github.com/appleboy/gin-jwt/pull/38
Karma
Test runner for JavaScript
Google
,
E2E.
JSDom Phantom
Sinon
Test spies, stubs and mocks for JavaScript.
Mocha + chai + sinon
Selenium
A browser automation framework and ecosystem
(WebDriver)
Node.js <=> WebDriver <=> Selenium Server <=> FF/Chrome/IE/Safari
Selenium-related
Protractor - E2E test framework for Angular apps
Angular
WebdriverIO - Selenium Syntax, Flexible,
Community.
Nightwatch
Automated testing and continous integration framework
based on node.js and selenium webdriver
test server assertions, tools.
Browser Automations
Casper
Navigation scripting and testing utility for PhantomJS and SlimerJS
Phantom(WebKit) Slim(Gecko)
nightmare
Phantom Slim, WebDriver, Electron Electron Extensive
Browser API
Unit Test Mocha + Chai Karma
Electron.
Zombie
Insanely fast, full-stack, headless browser testing using node.js
Headless browser
TestCafe
Casper
Navigation scripting and testing utility for
PhantomJS and SlimerJS
Phantom(WebKit) Slim(Gecko)
Nightmare
Phantom Slim, WebDriver,
Electron Electron Extensive
Browser API
Unit Test Mocha + Chai
Karma
Electron.
Zombie
Insanely fast, full-stack, headless browser
testing using node.js
Headless browser
TestCafe
Best tool alternative for Selenium
Automated browser testing for the modern web development stack
UI
UI
dom cheerio
Cucumber
BDD automated tests
RD PM
Business Crew: Gherkin
Developer:
JavaScript
BDD Scenario
Given
When
Then
Cucumber
Gherkins
Gherkin is the language that Cucumber
understands.
a Business Readable, Domain Specific
Language
Gherkin wiki
Cucumber
BDD
Gherkin Scenario
Cucumber
BDD
JavaScript Scenario
demo
https://github.com/xJkit/hello-integration-test
References
Just say no to more E2E tests
An Overview of JavaScript Testing in 2017
JavaScript Testing: Unit vs Functional vs
Integration Tests

Contenu connexe

Tendances

Tendances (20)

Codeception
CodeceptionCodeception
Codeception
 
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
 
Unit-testing and E2E testing in JS
Unit-testing and E2E testing in JSUnit-testing and E2E testing in JS
Unit-testing and E2E testing in JS
 
Easy automation.py
Easy automation.pyEasy automation.py
Easy automation.py
 
Polyglot automation - QA Fest - 2015
Polyglot automation - QA Fest - 2015Polyglot automation - QA Fest - 2015
Polyglot automation - QA Fest - 2015
 
Web ui tests examples with selenide, nselene, selene & capybara
Web ui tests examples with  selenide, nselene, selene & capybaraWeb ui tests examples with  selenide, nselene, selene & capybara
Web ui tests examples with selenide, nselene, selene & capybara
 
Codeception: introduction to php testing
Codeception: introduction to php testingCodeception: introduction to php testing
Codeception: introduction to php testing
 
Testing React Applications
Testing React ApplicationsTesting React Applications
Testing React Applications
 
Codeception
CodeceptionCodeception
Codeception
 
Efficient JavaScript Unit Testing, May 2012
Efficient JavaScript Unit Testing, May 2012Efficient JavaScript Unit Testing, May 2012
Efficient JavaScript Unit Testing, May 2012
 
From Good to Great: Functional and Acceptance Testing in WordPress.
From Good to Great: Functional and Acceptance Testing in WordPress.From Good to Great: Functional and Acceptance Testing in WordPress.
From Good to Great: Functional and Acceptance Testing in WordPress.
 
Selenide Alternative in Practice - Implementation & Lessons learned [Selenium...
Selenide Alternative in Practice - Implementation & Lessons learned [Selenium...Selenide Alternative in Practice - Implementation & Lessons learned [Selenium...
Selenide Alternative in Practice - Implementation & Lessons learned [Selenium...
 
Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...
Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...
Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...
 
Test automation with php codeception
Test automation with php codeceptionTest automation with php codeception
Test automation with php codeception
 
Testing with Codeception
Testing with CodeceptionTesting with Codeception
Testing with Codeception
 
Rich GUI Testing: Swing and JavaFX
Rich GUI Testing: Swing and JavaFXRich GUI Testing: Swing and JavaFX
Rich GUI Testing: Swing and JavaFX
 
Selenide alternative in Python - Introducing Selene [SeleniumCamp 2016]
Selenide alternative in Python - Introducing Selene [SeleniumCamp 2016]Selenide alternative in Python - Introducing Selene [SeleniumCamp 2016]
Selenide alternative in Python - Introducing Selene [SeleniumCamp 2016]
 
Testing with Codeception (Webelement #30)
Testing with Codeception (Webelement #30)Testing with Codeception (Webelement #30)
Testing with Codeception (Webelement #30)
 
Automation Abstraction Layers: Page Objects and Beyond
Automation Abstraction Layers: Page Objects and BeyondAutomation Abstraction Layers: Page Objects and Beyond
Automation Abstraction Layers: Page Objects and Beyond
 
Droidcon ES '16 - How to fail going offline
Droidcon ES '16 - How to fail going offlineDroidcon ES '16 - How to fail going offline
Droidcon ES '16 - How to fail going offline
 

Similaire à 軟體測試是在測試什麼?

GeeCON 2012 hurdle run through ejb testing
GeeCON 2012 hurdle run through ejb testingGeeCON 2012 hurdle run through ejb testing
GeeCON 2012 hurdle run through ejb testing
Jakub Marchwicki
 

Similaire à 軟體測試是在測試什麼? (20)

From devOps to front end Ops, test first
From devOps to front end Ops, test firstFrom devOps to front end Ops, test first
From devOps to front end Ops, test first
 
Testing of React JS app
Testing of React JS appTesting of React JS app
Testing of React JS app
 
Quest to the best test automation for low code development platform kherrazi ...
Quest to the best test automation for low code development platform kherrazi ...Quest to the best test automation for low code development platform kherrazi ...
Quest to the best test automation for low code development platform kherrazi ...
 
Behavior Driven Development by Example
Behavior Driven Development by ExampleBehavior Driven Development by Example
Behavior Driven Development by Example
 
Pragmatic Parallels: Java and JavaScript
Pragmatic Parallels: Java and JavaScriptPragmatic Parallels: Java and JavaScript
Pragmatic Parallels: Java and JavaScript
 
Testing In Java
Testing In JavaTesting In Java
Testing In Java
 
Testing In Java4278
Testing In Java4278Testing In Java4278
Testing In Java4278
 
Coding Naked
Coding NakedCoding Naked
Coding Naked
 
DDT Testing Library for Android
DDT Testing Library for AndroidDDT Testing Library for Android
DDT Testing Library for Android
 
Testing w-mocks
Testing w-mocksTesting w-mocks
Testing w-mocks
 
GeeCON 2012 hurdle run through ejb testing
GeeCON 2012 hurdle run through ejb testingGeeCON 2012 hurdle run through ejb testing
GeeCON 2012 hurdle run through ejb testing
 
Using Robots for App Testing
Using Robots for App Testing Using Robots for App Testing
Using Robots for App Testing
 
Joomla! Testing - J!DD Germany 2016
Joomla! Testing - J!DD Germany 2016Joomla! Testing - J!DD Germany 2016
Joomla! Testing - J!DD Germany 2016
 
Tdd is not about testing (OOP)
Tdd is not about testing (OOP)Tdd is not about testing (OOP)
Tdd is not about testing (OOP)
 
Testing In Java
Testing In JavaTesting In Java
Testing In Java
 
Test & behavior driven development
Test & behavior driven developmentTest & behavior driven development
Test & behavior driven development
 
Testing ASP.NET - Progressive.NET
Testing ASP.NET - Progressive.NETTesting ASP.NET - Progressive.NET
Testing ASP.NET - Progressive.NET
 
Unit Testing Android Applications
Unit Testing Android ApplicationsUnit Testing Android Applications
Unit Testing Android Applications
 
Test-Driven Design Insights@DevoxxBE 2023.pptx
Test-Driven Design Insights@DevoxxBE 2023.pptxTest-Driven Design Insights@DevoxxBE 2023.pptx
Test-Driven Design Insights@DevoxxBE 2023.pptx
 
Grails unit testing
Grails unit testingGrails unit testing
Grails unit testing
 

Dernier

CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
VishalKumarJha10
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
shinachiaurasa2
 

Dernier (20)

Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verifiedSector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
ManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide Deck
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
 

軟體測試是在測試什麼?