Test driven development with Vue.js by Sarah Dayan

Sdílet
Vložit
  • čas přidán 2. 07. 2024
  • Testing a component can be counter-intuitive. It requires a mental shift to wrap your head around the differences between testing components and testing plain scripts, knowing what to test and understanding the line between unit and end-to-end tests.
    TDD makes everything easier. Instead of writing tests by examining all bits and pieces of a finished project, and trying to guess what you should cover, you’re doing the opposite. You’re starting from actual specs, a list of things that the component should do, without caring about how it does it. This way, you’re ensuring that all you test is the public API of your component, but you’re also guaranteeing you don’t forget anything.
    In this talk, we’ll cover why TDD is an ideal method for testing Vue components properly, and we’ll do it together live. We’ll deep dive into why TDD works the way it does, and how it can bring you full confidence over iterating on your Vue projects. At the end of the talk, you will know exactly what to test in your Vue components, and how to do it efficiently.
  • Věda a technologie

Komentáře • 40

  • @VueConfToronto
    @VueConfToronto  Před 4 lety +1

    Find all conference videos here: vuetoronto.com/videos
    Signup for conference updates here: vuetoronto.com
    Want to learn Vue 3.0 from the experts? bit.ly/2v8QALV

  • @AdrienJOLY
    @AdrienJOLY Před 4 lety +23

    That’s a very good introduction (and motivation) to TDD, applied to front-end development with Vue.js. Thank you, Sarah!

  • @simonhunt9857
    @simonhunt9857 Před 4 lety +7

    Coming from a PHP background I was familiar with TDD but how to apply these principles to Vue development had never really 'clicked' for me until watching this video. So thanks for helping me to have that 'aha' moment!

  • @EricClaeren
    @EricClaeren Před 4 lety +3

    Great talk and the message is delivered very well! Thanks you Sarah.

  • @JoeSchroecker
    @JoeSchroecker Před 4 lety +4

    Love it! Finally the 2nd step makes sense to me!

  • @user-hf6ti7ls9t
    @user-hf6ti7ls9t Před 3 lety +1

    Thank you! Its really simple to understand with 3 steps

  • @TruthMonster7777
    @TruthMonster7777 Před 2 lety

    I loved this. I was trying TDD but was not confident in the approach but the way you explained made it very clear to me why this is necessary and also how to approach front-end components Test-driven development.

  • @qianbang_
    @qianbang_ Před 4 lety

    This really helps how we code and helps see how to structure or refactor it.

  • @assaulth3ro911
    @assaulth3ro911 Před 3 lety

    Well done presentation. It kept me focused, it was simple, and it explained the core principles as I need to understand them! Thank you. :)

  • @kamalhm-dev
    @kamalhm-dev Před 4 lety +1

    one of the best, Sarah

  • @DodaGarcia
    @DodaGarcia Před 3 lety +1

    Omg she's so awesome! I would watch her teach stuff all day

  • @jajappp
    @jajappp Před 2 lety +1

    Thanks for sharing a drop of knowledge, rich content.
    Congratulations!
    very well presented.
    Success!

  • @victornaut
    @victornaut Před 3 lety +1

    Jeez I wish I could speak that succinctly. Great talk.

  • @gzull90
    @gzull90 Před 4 lety

    really nice presentation. thx!

  • @chenrvn
    @chenrvn Před 4 lety +3

    Excellent Talk, Thanks!
    1. You are awesome!
    2. The issue with TDD and Testing in global is the setup configuration and sometimes the time to run and get feedback from them.
    when u pass it over (as u say) the tests written is easier and faster
    Thanks for your explanation, very clear and U R Rock in live coding :)

    • @TheRedlag
      @TheRedlag Před 4 lety +2

      Thank you Chen! Unit tests should run fast, because they test small units and don't touch I/O. In my presentation, they took a bit longer than usual because somehow, when I set my computer offline, Jest suddenly became slow. In reality and on a daily basis, they're blazing fast.

    • @chenrvn
      @chenrvn Před 4 lety

      BTW i am just wrote a medium article full influence to your presentation in Angular :) [off course full feed back to u]
      So Thanks 4 your expression :)

  • @avimehenwal
    @avimehenwal Před 3 lety +4

    I wrote first test suite for my vue components yesterday. took me only 2 days XD

  • @jannesbehrens2163
    @jannesbehrens2163 Před 4 lety +3

    thank you!

  • @ultrasamad
    @ultrasamad Před 4 lety +1

    Great talk.

  • @nezarfadle7715
    @nezarfadle7715 Před 3 lety

    Great talk!

  • @patrikprochazka1269
    @patrikprochazka1269 Před 4 lety +1

    A really good one!

  • @mluevanos
    @mluevanos Před 4 lety

    Great talk

  • @Caranor
    @Caranor Před 3 lety

    2 minutes into the video and I'm already convinced

  •  Před 4 lety +1

    thanks !

  • @jonnysongs
    @jonnysongs Před 4 lety +1

    Good talk

  • @programwithmanthan5868

    Thank you Sarah for the introduction, VueConf Toronto please upload code samples as well with the video.

  • @SolidIncMedia
    @SolidIncMedia Před 4 lety +1

    This just serves to remind me that I'm really bad at writing tests. That is, only one project I've ever written has used tests. And they're out of date. And they're badly written tests.
    I should put the ideas in this video into practice before I push to production again..

  • @DodaGarcia
    @DodaGarcia Před 3 lety +1

    As an (embarrassingly recent) adopter of TDD, I now kinda laugh at myself from all the years I spent thinking I couldn;'t afford the time to write the tests first.
    It does take time, obviously. But it takes at least one order of magnitude less time than it does to debug and fix broken code, especially when the fixes on one part start breaking another.
    It's like that great Jack Bergman quote: "There's never enough time to do it right, but there's always enough time to do it over."

  • @yun-ruzeng5026
    @yun-ruzeng5026 Před 3 lety

    gooooooooood, love you

  • @oopserv316
    @oopserv316 Před 3 lety

    ty

  • @dokem
    @dokem Před 4 lety

    yes mam

  • @zozo1603
    @zozo1603 Před 3 lety

    Why is "a non-regression test is always nice"?
    If we used storybook's storyshots (which is actually using a jest feature) with puppeteer, we would get for free al the tests, that Sarah wrote in this demo.
    I love storyshots:D I barely need e2e or unit tests next to them to feel confident about my code.

  • @canaloneliojr
    @canaloneliojr Před 4 lety

    Does anyone know the vscode theme she is using?

  • @hellocheng7071
    @hellocheng7071 Před 3 lety

    great great great

  • @dopamine_Seeker
    @dopamine_Seeker Před 2 lety

    When I visit tailwind page I see her face now I'm seeing her video look more fater

  • @Andrey-il8rh
    @Andrey-il8rh Před rokem

    Now I know who is displayed on the main page of Tailwind 😂

  • @MrKaki90
    @MrKaki90 Před 2 lety

    99% TDD 1% Vue testing

  •  Před 4 lety

    1:37 Uncle Bob said that not Yoda :)