user2573410
user2573410

Reputation: 141

AngularJS testing? Unit Testing and E2E testing?

I have been reading that karma is used for angular unit testing and protractor is for end-to-end testing. If we want to have both unit and E2E testing in my angular application, then how do should it look like? How do I incorporate both? In order to have both of these tests included in our suite, should we use both karma (for unit testing) and protractor (for E2E testing) for the same application? Is that a healthy way to go about it? P.S: Post is open to all the approaches to achieve this.

Upvotes: 3

Views: 1639

Answers (1)

Stepan Suvorov
Stepan Suvorov

Reputation: 26236

It's possible to run unit tests on Protractor but it's better to separate unit and e2e test runners.

https://github.com/angular/protractor/blob/master/docs/faq.md#why-both-karma-and-protractor-when-do-i-use-which

Upvotes: 2

Related Questions