From the course: Angular Essential Training
Unlock the full course today
Join today to access over 24,900 courses taught by industry experts.
Overview of unit testing - Angular Tutorial
From the course: Angular Essential Training
Overview of unit testing
- Unit testing is a way to make sure the code you write works the way you expect it to. Every angular developer should know how to test code. This is especially important when working on a team with many developers writing code at the same time. You want to make sure your code doesn't break someone else's work. As of this recording, angular comes with the Jasmine Test Framework and Karma Test Runner for writing and running unit tests. You can use a different testing framework if you want to, just be sure to follow the official recommendations for whatever you use. We use the NG test command to run the test suite for our project. It's also common to map the NG test command to an N P M test command. I like using the N P M command to make sure I use the locally installed version of NG instead of the globally installed version of my machine. It also comes in handy if I have a standard set of command line options. I…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.