SlideShare a Scribd company logo
1 of 30
Outside-In Testing
In Vue
Josh Justice
learntdd.in/vue
CodingItWrong
Talk to us about Vue projects!
Free 30 Day Trial
thefrontier@bignerdranch.com
Vue is one of the most
testable frontend frameworks
Questions! 🤔
• Do I write the test or production code first?
• What do I test first?
• How many E2E/unit tests do I write?
• How much test code do I write at a time?
Production code?
• Do I test every line of code and configuration?
Test-Driven
Development:
An approach to testing that
provides a consistent set of
answers to those questions.
A note on test coverage
https://www.cypress.io/how-it-works/
"One of our goals was to make test-driven
development a reality for end-to-end
testing. Cypress is at its best when you use
it as you build your application. We give you
the power to code as fast as possible.”
“…unlock the ability to do TDD with full end-
to-end tests for the very first time…The end
result is that you will have developed more,
your code will be better, and it will be
completely tested.”
https://www.cypress.io/how-it-works/
learntdd.in/vue
live demo 😅
Requirement: as a
user, I want to be able
to send a message.
Why TDD?
Confidence it works.
100% test coverage.
Minimal code.
Ability to refactor.
Ability to ship quickly.
Makes you happier.
TDD can be one of
your distinctives
To Learn More
learntdd.in/vue
To Learn More
Apply for future positions!
bignerdranch.com/about/careers
🤔 Questions?
Thanks! 🤔
@CodingItWrong
learntdd.in/vue

More Related Content

What's hot

Code review
Code reviewCode review
Code review
Aleksey Solntsev
 
How to be proud when you are done
How to be proud when you are doneHow to be proud when you are done
How to be proud when you are done
Aleksey Solntsev
 

What's hot (20)

Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven Development
 
Intro to automated testing
Intro to automated testingIntro to automated testing
Intro to automated testing
 
Presentation_TDD
Presentation_TDDPresentation_TDD
Presentation_TDD
 
Who let the robot out? - Building high quality software with Continuous Integ...
Who let the robot out? - Building high quality software with Continuous Integ...Who let the robot out? - Building high quality software with Continuous Integ...
Who let the robot out? - Building high quality software with Continuous Integ...
 
Continuous Delivery - the missing parts - Paul Stack
Continuous Delivery - the missing parts - Paul StackContinuous Delivery - the missing parts - Paul Stack
Continuous Delivery - the missing parts - Paul Stack
 
Nascenia: Road to Software Industry
Nascenia: Road to Software IndustryNascenia: Road to Software Industry
Nascenia: Road to Software Industry
 
Tdd2018 state of the software quality in Germany
Tdd2018 state of the software quality in GermanyTdd2018 state of the software quality in Germany
Tdd2018 state of the software quality in Germany
 
Drulenium - Testing Made Easy
Drulenium - Testing Made EasyDrulenium - Testing Made Easy
Drulenium - Testing Made Easy
 
Introduction cypress
Introduction cypressIntroduction cypress
Introduction cypress
 
Continuous Integration at T3CON08
Continuous Integration at T3CON08Continuous Integration at T3CON08
Continuous Integration at T3CON08
 
Code review
Code reviewCode review
Code review
 
Tester vs Developer
Tester vs DeveloperTester vs Developer
Tester vs Developer
 
XP Injection
XP InjectionXP Injection
XP Injection
 
How to be proud when you are done
How to be proud when you are doneHow to be proud when you are done
How to be proud when you are done
 
Boquet manager
Boquet managerBoquet manager
Boquet manager
 
When you get lost in api testing #ForumPHP
When you get lost in api testing #ForumPHPWhen you get lost in api testing #ForumPHP
When you get lost in api testing #ForumPHP
 
TGT#16 - Pain of test automatization in PAAS/SAAS solutions - Krzysztof Lembi...
TGT#16 - Pain of test automatization in PAAS/SAAS solutions - Krzysztof Lembi...TGT#16 - Pain of test automatization in PAAS/SAAS solutions - Krzysztof Lembi...
TGT#16 - Pain of test automatization in PAAS/SAAS solutions - Krzysztof Lembi...
 
The four generations of test automation
The four generations of test automationThe four generations of test automation
The four generations of test automation
 
[Quang nguyen] Continuous Integration XP Day 2015 Vietnam Danang
[Quang nguyen] Continuous Integration XP Day 2015 Vietnam Danang[Quang nguyen] Continuous Integration XP Day 2015 Vietnam Danang
[Quang nguyen] Continuous Integration XP Day 2015 Vietnam Danang
 
Testing the way it should be
Testing the way it should beTesting the way it should be
Testing the way it should be
 

Similar to Outside-in Testing in Vue with Cypress

Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
BestBrains
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
Einar Ingebrigtsen
 

Similar to Outside-in Testing in Vue with Cypress (20)

Test-Driven Development In Action
Test-Driven Development In ActionTest-Driven Development In Action
Test-Driven Development In Action
 
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
 
Test Driven Development and Automation
Test Driven Development and AutomationTest Driven Development and Automation
Test Driven Development and Automation
 
Bootstrapping Quality
Bootstrapping QualityBootstrapping Quality
Bootstrapping Quality
 
Test driven development and react js application go hand in hand
Test driven development and react js application go hand in handTest driven development and react js application go hand in hand
Test driven development and react js application go hand in hand
 
Automatic for the People
Automatic for the PeopleAutomatic for the People
Automatic for the People
 
Python and test
Python and testPython and test
Python and test
 
Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven Development
 
Introduction to Automated Testing
Introduction to Automated TestingIntroduction to Automated Testing
Introduction to Automated Testing
 
Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
 
iOS Test-Driven Development
iOS Test-Driven DevelopmentiOS Test-Driven Development
iOS Test-Driven Development
 
How to run an Enterprise PHP Shop
How to run an Enterprise PHP ShopHow to run an Enterprise PHP Shop
How to run an Enterprise PHP Shop
 
Testing: the more you do it, the more you'll like it
Testing: the more you do it, the more you'll like itTesting: the more you do it, the more you'll like it
Testing: the more you do it, the more you'll like it
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
 
Automated tests
Automated testsAutomated tests
Automated tests
 
The Professional Programmer
The Professional ProgrammerThe Professional Programmer
The Professional Programmer
 
Software Development Standard Operating Procedure
Software Development Standard Operating Procedure Software Development Standard Operating Procedure
Software Development Standard Operating Procedure
 
Joe Cisar - Everything I Know About TDD - Agile Midwest 2019
Joe Cisar - Everything I Know About TDD - Agile Midwest 2019Joe Cisar - Everything I Know About TDD - Agile Midwest 2019
Joe Cisar - Everything I Know About TDD - Agile Midwest 2019
 
Unit Testing in JavaScript
Unit Testing in JavaScriptUnit Testing in JavaScript
Unit Testing in JavaScript
 
Tdd
TddTdd
Tdd
 

More from Josh Justice

Designing Effective Tests with React Testing Library - React Day Berlin 2022
Designing Effective Tests with React Testing Library - React Day Berlin 2022Designing Effective Tests with React Testing Library - React Day Berlin 2022
Designing Effective Tests with React Testing Library - React Day Berlin 2022
Josh Justice
 

More from Josh Justice (16)

Effective Detox Testing - React Advanced 2023
Effective Detox Testing - React Advanced 2023Effective Detox Testing - React Advanced 2023
Effective Detox Testing - React Advanced 2023
 
Designing Effective Tests with React Testing Library - React Summit 2023
Designing Effective Tests with React Testing Library - React Summit 2023Designing Effective Tests with React Testing Library - React Summit 2023
Designing Effective Tests with React Testing Library - React Summit 2023
 
Testing React Native Apps - Chain React 2023
Testing React Native Apps - Chain React 2023Testing React Native Apps - Chain React 2023
Testing React Native Apps - Chain React 2023
 
Designing Effective Tests with React Testing Library - React Day Berlin 2022
Designing Effective Tests with React Testing Library - React Day Berlin 2022Designing Effective Tests with React Testing Library - React Day Berlin 2022
Designing Effective Tests with React Testing Library - React Day Berlin 2022
 
Building for Mobile and Web with Expo - React Day Berlin 2022
Building for Mobile and Web with Expo - React Day Berlin 2022Building for Mobile and Web with Expo - React Day Berlin 2022
Building for Mobile and Web with Expo - React Day Berlin 2022
 
Intro to React Native Testing Library
Intro to React Native Testing LibraryIntro to React Native Testing Library
Intro to React Native Testing Library
 
Building for Mobile and Web with Expo - React Advanced London 2022
Building for Mobile and Web with Expo - React Advanced London 2022Building for Mobile and Web with Expo - React Advanced London 2022
Building for Mobile and Web with Expo - React Advanced London 2022
 
Getting Better All the Time: How to Escape Bad Code
Getting Better All the Time: How to Escape Bad CodeGetting Better All the Time: How to Escape Bad Code
Getting Better All the Time: How to Escape Bad Code
 
Sustainable Learning - ReactATL Jan 2022
Sustainable Learning - ReactATL Jan 2022Sustainable Learning - ReactATL Jan 2022
Sustainable Learning - ReactATL Jan 2022
 
Building an App for Mobile and Web with Expo
Building an App for Mobile and Web with ExpoBuilding an App for Mobile and Web with Expo
Building an App for Mobile and Web with Expo
 
User-Modifiable Software: Smalltalk and HyperCard
User-Modifiable Software: Smalltalk and HyperCardUser-Modifiable Software: Smalltalk and HyperCard
User-Modifiable Software: Smalltalk and HyperCard
 
Practical Accessibility (A11y)
Practical Accessibility (A11y)Practical Accessibility (A11y)
Practical Accessibility (A11y)
 
Old Solutions to New Testing Problems
Old Solutions to New Testing ProblemsOld Solutions to New Testing Problems
Old Solutions to New Testing Problems
 
Test-Driven Development in Vue with Cypress
Test-Driven Development in Vue with CypressTest-Driven Development in Vue with Cypress
Test-Driven Development in Vue with Cypress
 
Test-Driven Development in React with Cypress
Test-Driven Development in React with CypressTest-Driven Development in React with Cypress
Test-Driven Development in React with Cypress
 
Newbie's Guide to Contributing to Babel
Newbie's Guide to Contributing to BabelNewbie's Guide to Contributing to Babel
Newbie's Guide to Contributing to Babel
 

Recently uploaded

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
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
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
 

Recently uploaded (20)

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
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
%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
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
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
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
 
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
 
ManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide Deck
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
 
%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
 
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
 
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
 

Outside-in Testing in Vue with Cypress

Editor's Notes

  1. We are adding more and more web content across different frameworks Just added a talk about testing Vue components Also about extracting a component under test; it’s in React but the principles apply to Vue Free trial to check it out and let us know what you want to see
  2. Who here uses the Vue web pack template?
  3. How many of you use the Webpack template? E2E and component testing built in
  4. But you still have a lot of questions
  5. Diagram from Growing Object Oriented Software Guided by Tests
  6. Outside-in TDD
  7. Webpack template has Istanbul code coverage built in Specifically it’s unit test coverage The people I’ve learned testing from, whose opinions I respect the most, don’t talk about percentage coverage Here’s why. In TDD, end-to-end tests necessarily cover everything You don’t need a unit test to cover everything; it doesn’t deliver value
  8. Cypress was specifically built with a focus on TDD Completely free to use Nearing 1.0 release Based in Atlanta, some Cypress folks in the room—introduce them
  9. Cypress was specifically built with a focus on TDD Completely free to use Nearing 1.0 release Based in Atlanta, some Cypress folks in the room—introduce them
  10. Cypress was specifically built with a focus on TDD Completely free to use Nearing 1.0 release Based in Atlanta, some Cypress folks in the room—introduce them I can’t vouch for the fact of whether you can do TDD with Nightwatch. But I don’t hear of many people doing it
  11. Several Vue projects for a major company Apply for future positions