paint-brush
How to Write Your First Unit Test With Jasmineby@marcinwosinek
588 reads
588 reads

How to Write Your First Unit Test With Jasmine

by Marcin Wosinek4mAugust 17th, 2022
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

In a previous article, I showed pseudocode examples of unit testing *pure functions*. I got an excellent question—so how do I start testing my code then? Let’s take a more practical look at the same, simple case for testing. The code we are going to test will work the same way on browser or Node.js. We will create a new file `./spec-spec-test.js that matches the convention inside the.spec/pure-functions folder.
featured image - How to Write Your First Unit Test With Jasmine
Marcin Wosinek HackerNoon profile picture
Marcin Wosinek

Marcin Wosinek

@marcinwosinek

I'm a JavaScript developer. I'm here to teach you useful skills, so you can succeed in your work & private projects.

Learn More
LEARN MORE ABOUT @MARCINWOSINEK'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

Marcin Wosinek HackerNoon profile picture
Marcin Wosinek@marcinwosinek
I'm a JavaScript developer. I'm here to teach you useful skills, so you can succeed in your work & private projects.

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite
Also published here