SlideShare a Scribd company logo
JavaScript Testing—
Technically not a number…
Justin Obney, Front-End Dev
Gone are the days of old
Any application that can be
written in JavaScript, will be
written in JavaScript
-- Atwood’s
Law
JS is everywhere
That no one thinks they need to
actually learn how it works.
Looks like C or Java… How
hard could it be?
JavaScript is so
approachable
• The old way
• Frameworks
• The lies
• Where to start
• Tooling
• Who knows?
The Agenda
“Whenever you are tempted to
type something into a print
statement or a debugger
expression, write it as a test
instead.”
—Martin Fowler
When do I write a test?
Testing Frameworks
•A unit test is code that executes
part of your production code
with an expectation on the
result.
•Unit vs. Integration
•Mocking & Stubbing
•Vocabulary
But testing is hard…
But the DOM
Tooling
TEST’EM
I see you are on a Mac…
But what about Windows?
But does it scale?
In closing
Unit testing JS = SQLSat 324
Thank You
justinobney@gmail.com
twitter.com/justinobney
github.com/justinobney
apply@envoccareers.com

More Related Content

ODP
Sqa days2013
PPTX
Prototype that first
ODP
Assorted TDD tips
PDF
7 Surprising Polymer Takeaways
PPT
what's blocking our way
PPTX
Exceptions: Why, When, How and Where!
PDF
People & Products – Lessons learned from the daily IT madness
PPT
Isotope
Sqa days2013
Prototype that first
Assorted TDD tips
7 Surprising Polymer Takeaways
what's blocking our way
Exceptions: Why, When, How and Where!
People & Products – Lessons learned from the daily IT madness
Isotope

What's hot (18)

PPTX
A Mockery of a persentation
PDF
Fast end-to-end-tests
PPTX
Isotope
PPTX
A/B Testing That Matters
PDF
It's Not Just a Phase: Learning To Love Full Stack Development
PDF
Nhu Viet Nguyen "Why C++ is Becoming a Necessity for QA Automation"
ODP
Learned from Woodworking
PDF
7 lessons learned building high availability / performance systems - CM2015
PDF
Good Enough Prototype (Ivan Pashko Product Stream)
PPTX
Test Driven Development: More Development Than Ever
PDF
The Way of The Software Craftsman # Part One: The Beginning
PPTX
Lean Responsive
PPTX
Session #3: "It Works on My Machine!" Closing the Loop Between Development & ...
PDF
How to code in the XXI century without losing your head
PPTX
Felt - Front end load testing
PPTX
Testing javascript
PDF
The Front End Testing Frontier - RubyConf 2010
PDF
Understand the system
A Mockery of a persentation
Fast end-to-end-tests
Isotope
A/B Testing That Matters
It's Not Just a Phase: Learning To Love Full Stack Development
Nhu Viet Nguyen "Why C++ is Becoming a Necessity for QA Automation"
Learned from Woodworking
7 lessons learned building high availability / performance systems - CM2015
Good Enough Prototype (Ivan Pashko Product Stream)
Test Driven Development: More Development Than Ever
The Way of The Software Craftsman # Part One: The Beginning
Lean Responsive
Session #3: "It Works on My Machine!" Closing the Loop Between Development & ...
How to code in the XXI century without losing your head
Felt - Front end load testing
Testing javascript
The Front End Testing Frontier - RubyConf 2010
Understand the system
Ad

Similar to Unit testing JS = SQLSat 324 (20)

PPTX
Zero to Testing in JavaScript
PDF
Testacular
PDF
JAVASCRIPT TDD(Test driven Development) & Qunit Tutorial
PDF
JAVASCRIPT Test Driven Development & Jasmine
PPTX
Testing JavaScript Applications
PDF
Efficient JavaScript Unit Testing, March 2013
PDF
Unit Testing in JavaScript
PDF
Unit-testing and E2E testing in JS
PPTX
MidwestJS Zero to Testing
PPTX
Angular Unit Test
PPT
Pragmatic Parallels: Java and JavaScript
PDF
Efficient JavaScript Unit Testing, May 2012
PDF
Efficient JavaScript Unit Testing, JavaOne China 2013
PPT
JavaScript Unit Testing
PPTX
JavaScript Unit Testing
PDF
Unit testing (Exploring the other side as a tester)
PDF
Testing in FrontEnd World by Nikita Galkin
PPT
Javascript unit testing framework
PPT
8 - Javascript unit testing framework
PDF
Никита Галкин "Testing in Frontend World"
Zero to Testing in JavaScript
Testacular
JAVASCRIPT TDD(Test driven Development) & Qunit Tutorial
JAVASCRIPT Test Driven Development & Jasmine
Testing JavaScript Applications
Efficient JavaScript Unit Testing, March 2013
Unit Testing in JavaScript
Unit-testing and E2E testing in JS
MidwestJS Zero to Testing
Angular Unit Test
Pragmatic Parallels: Java and JavaScript
Efficient JavaScript Unit Testing, May 2012
Efficient JavaScript Unit Testing, JavaOne China 2013
JavaScript Unit Testing
JavaScript Unit Testing
Unit testing (Exploring the other side as a tester)
Testing in FrontEnd World by Nikita Galkin
Javascript unit testing framework
8 - Javascript unit testing framework
Никита Галкин "Testing in Frontend World"
Ad

Recently uploaded (20)

PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
PDF
System and Network Administraation Chapter 3
PDF
System and Network Administration Chapter 2
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PDF
Digital Strategies for Manufacturing Companies
PPTX
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PPTX
ai tools demonstartion for schools and inter college
PPTX
Introduction to Artificial Intelligence
PDF
Nekopoi APK 2025 free lastest update
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
Odoo POS Development Services by CandidRoot Solutions
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PDF
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
PPTX
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PPTX
history of c programming in notes for students .pptx
PPTX
CHAPTER 2 - PM Management and IT Context
PDF
Odoo Companies in India – Driving Business Transformation.pdf
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
System and Network Administraation Chapter 3
System and Network Administration Chapter 2
How to Migrate SBCGlobal Email to Yahoo Easily
Digital Strategies for Manufacturing Companies
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
Internet Downloader Manager (IDM) Crack 6.42 Build 41
ai tools demonstartion for schools and inter college
Introduction to Artificial Intelligence
Nekopoi APK 2025 free lastest update
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Odoo POS Development Services by CandidRoot Solutions
Wondershare Filmora 15 Crack With Activation Key [2025
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
history of c programming in notes for students .pptx
CHAPTER 2 - PM Management and IT Context
Odoo Companies in India – Driving Business Transformation.pdf

Unit testing JS = SQLSat 324

Editor's Notes

  • #2: Who am I Envoc .Net beginning now they pay me to write JavaScript The web is changing rapidly The good old days WEB FORMS: post a form let the server build 1/2 MB or html and then send it back to the client to change a radio button … Cue magic
  • #3: Some of you may still live there... Get out now… JavaScript on rise
  • #4: Atwood’s Law CodingHorror StackOverflow it runs everywhere The server Mobile apps TVs? PS4? Heard of the web.. it is here to stay.
  • #5: 0.1 + 0.2
  • #6: console.log has the nasty risk of introducing bugs all on its own. enter dev tools (`debugger;`)
  • #8: QUnit older, more support mocha can drop in any* assertion library jasmine headless browser support built in spies & mocks
  • #9: Vocabulary A unit test is code that executes part of your production code with an expectation on the result. Unit vs integration unit - should be able to trust they should all be green integration - sometimes fail due to circumstance/environment Mocking and stubbing Mocks - you expect to assert against value (1 per test) Stubs - fake calls out. can have many
  • #12: ----- Meeting Notes (4/8/14 20:43) ----- Gmail, Facebook, Twitter, Azure Management Portal Models, Controllers, Services, Smart Caching, DI -- All things that can live in the client now
  • #13: ----- Meeting Notes (4/8/14 20:48) ----- Most of the tooling you will find will run on NodeJS Node has made Windows a first class citizen. You can integrate it into most of your existing CI servers. The only thing stopping you is you.
  • #14: This is not library code. There is very little DOM manipulation going on here (SPA). This is application logic.