SlideShare une entreprise Scribd logo
1  sur  7
Télécharger pour lire hors ligne
Test Driven Development
in Node.js apps
TechTalk
by Ihor Yamshchykov
• “Unit tests” test individual units of code in isolation (for instance, individual
functions). They are fast and you usually have a lot of them.
• “Integration tests” test the integrations between different units, for
example the interaction between one module and its dependencies.
• “E2E (or end-to-end) tests” test the system as a whole, from the UI down
to the data store, and back.
TDD Benefits
• Application stability
• Easy refactoring
• Easy improvements
• Reusable code
• Safe production
TDD Drawbacks
• Development speed delay
• Bad test implementation
• May require additional resources
When writing tests ?
• Keep simple
• Single responsibility
• Separate by logic
• Make test fast
• Test more
Demo

Contenu connexe

Tendances

Performance Testing Session - OSSCamp 2014
Performance Testing Session -  OSSCamp 2014Performance Testing Session -  OSSCamp 2014
Performance Testing Session - OSSCamp 2014
OSSCube
 
Installation testing
Installation testingInstallation testing
Installation testing
Robin0590
 

Tendances (17)

Performance Testing Session - OSSCamp 2014
Performance Testing Session -  OSSCamp 2014Performance Testing Session -  OSSCamp 2014
Performance Testing Session - OSSCamp 2014
 
Nunit
NunitNunit
Nunit
 
Testing
TestingTesting
Testing
 
Unit Testing Using N Unit
Unit Testing Using N UnitUnit Testing Using N Unit
Unit Testing Using N Unit
 
Significance Of Component Base Architecture
Significance Of Component Base ArchitectureSignificance Of Component Base Architecture
Significance Of Component Base Architecture
 
Software Architecture
Software ArchitectureSoftware Architecture
Software Architecture
 
Why NXTware Remote for Jenkins
Why NXTware Remote for JenkinsWhy NXTware Remote for Jenkins
Why NXTware Remote for Jenkins
 
Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven Development
 
Jmeter
JmeterJmeter
Jmeter
 
Testing JavaScript Applications
Testing JavaScript ApplicationsTesting JavaScript Applications
Testing JavaScript Applications
 
JavaScript Unit Testing
JavaScript Unit TestingJavaScript Unit Testing
JavaScript Unit Testing
 
Unit Testing (C#)
Unit Testing (C#)Unit Testing (C#)
Unit Testing (C#)
 
Unit tests benefits
Unit tests benefitsUnit tests benefits
Unit tests benefits
 
Tools for Software Testing
Tools for Software TestingTools for Software Testing
Tools for Software Testing
 
How to Build Your Own Test Automation Framework?
How to Build Your Own Test Automation Framework?How to Build Your Own Test Automation Framework?
How to Build Your Own Test Automation Framework?
 
Installation testing
Installation testingInstallation testing
Installation testing
 
Continuous Integration & Package Management 101
Continuous Integration & Package Management 101Continuous Integration & Package Management 101
Continuous Integration & Package Management 101
 

Plus de TechMagic

Plus de TechMagic (10)

K is for Kotlin
K is for KotlinK is for Kotlin
K is for Kotlin
 
Intro to vue.js
Intro to vue.jsIntro to vue.js
Intro to vue.js
 
Android notifications. testing guideline
Android notifications. testing guidelineAndroid notifications. testing guideline
Android notifications. testing guideline
 
Coaching
CoachingCoaching
Coaching
 
Angular 2 vs React. What to chose in 2017?
Angular 2 vs React. What to chose in 2017?Angular 2 vs React. What to chose in 2017?
Angular 2 vs React. What to chose in 2017?
 
Getting started with Stripe
Getting started with StripeGetting started with Stripe
Getting started with Stripe
 
Android developer options & android sdk tools (for qa)
Android developer options & android sdk tools (for qa)Android developer options & android sdk tools (for qa)
Android developer options & android sdk tools (for qa)
 
Tips and Tricks for email communication with customer
Tips and Tricks for email communication with customerTips and Tricks for email communication with customer
Tips and Tricks for email communication with customer
 
OS X Server as CI for iOS
OS X Server as CI for iOSOS X Server as CI for iOS
OS X Server as CI for iOS
 
TechMagic - Development Studio for Startups (iOS, Android, Node.js)
TechMagic - Development Studio for Startups (iOS, Android, Node.js)TechMagic - Development Studio for Startups (iOS, Android, Node.js)
TechMagic - Development Studio for Startups (iOS, Android, Node.js)
 

Dernier

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Dernier (20)

Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 

Test Driven Development in Node.js apps

  • 1. Test Driven Development in Node.js apps TechTalk by Ihor Yamshchykov
  • 2. • “Unit tests” test individual units of code in isolation (for instance, individual functions). They are fast and you usually have a lot of them. • “Integration tests” test the integrations between different units, for example the interaction between one module and its dependencies. • “E2E (or end-to-end) tests” test the system as a whole, from the UI down to the data store, and back.
  • 3.
  • 4. TDD Benefits • Application stability • Easy refactoring • Easy improvements • Reusable code • Safe production
  • 5. TDD Drawbacks • Development speed delay • Bad test implementation • May require additional resources
  • 6. When writing tests ? • Keep simple • Single responsibility • Separate by logic • Make test fast • Test more