Re-thinking developer experience • Product @Gitpod 🍊 Helping folks get their start in cloud • @openupthecloud ☁️ AWS Community Builder 🛠 Replies in GIFS 😃
Nice, Vlad! Nice to see you writing 😁 I've been thinking for a long time to try and write up some fairly extensive run through of JS test mocking etc. Covering things like philosophy of mocking and what not. That was a huge hurdle for me to get into TDD, as you need to have all the "tools" before you begin.
That said, I literally now cannot code without tests. The prospect of compiling and then refreshing a browser or API and manually verifying fills me with horror. I'd much rather spend the first X amount of time writing some decent tests before I begin. I can't often fathom the idea of not doing that.
Re-thinking developer experience • Product @Gitpod 🍊 Helping folks get their start in cloud • @openupthecloud ☁️ AWS Community Builder 🛠 Replies in GIFS 😃
Also nice that you wrote your own little test runner. I remember watching some tutorial where someone did that and I remember being like... "oh... I can do that?". Then I started kicking myself since the true barrier to entry for tests is just one small test function (as you did). There's pretty much no excuse or reason not to.
I wanted to show that writing tests is all about a way of thinking and that it helps you navigate the problem. I like the idea around mocking/not mocking as have fallen to that trap too before where mocked out things to the point - so if will find more time for writing may write some more stuff around testing :)
I had to recently try and explain how testing works and realised that we are too used to tooling and in reality all it is just a function that makes sure that result matches the expectation. The frameworks are out there to make a lot of things easier but the basics are still the same.
And as you said - I think once it clicks and you see the benefit of it you just don't want to go back to not doing it :)
As someone on LinkedIn said: "I never understood why someone wouldn't write lots of tests! What kind of person doesn't like to consistently prove themselves right?"
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Nice, Vlad! Nice to see you writing 😁 I've been thinking for a long time to try and write up some fairly extensive run through of JS test mocking etc. Covering things like philosophy of mocking and what not. That was a huge hurdle for me to get into TDD, as you need to have all the "tools" before you begin.
That said, I literally now cannot code without tests. The prospect of compiling and then refreshing a browser or API and manually verifying fills me with horror. I'd much rather spend the first X amount of time writing some decent tests before I begin. I can't often fathom the idea of not doing that.
Also nice that you wrote your own little test runner. I remember watching some tutorial where someone did that and I remember being like... "oh... I can do that?". Then I started kicking myself since the true barrier to entry for tests is just one small test function (as you did). There's pretty much no excuse or reason not to.
Thanks Lou!
I wanted to show that writing tests is all about a way of thinking and that it helps you navigate the problem. I like the idea around mocking/not mocking as have fallen to that trap too before where mocked out things to the point - so if will find more time for writing may write some more stuff around testing :)
I had to recently try and explain how testing works and realised that we are too used to tooling and in reality all it is just a function that makes sure that result matches the expectation. The frameworks are out there to make a lot of things easier but the basics are still the same.
And as you said - I think once it clicks and you see the benefit of it you just don't want to go back to not doing it :)
As someone on LinkedIn said: "I never understood why someone wouldn't write lots of tests! What kind of person doesn't like to consistently prove themselves right?"