-
Notifications
You must be signed in to change notification settings - Fork 878
StyleGuide - In Testing #1160
Comments
I suggest to drop the styles of type:
Coupling the style guide with specific testing framework, test runner sounds like a bad idea.
|
Totally agree. Also, there are people who don't like Jasmine and use Mocha or something else with success. |
Good points. Let's consider where we are with testing right now. Today we know how to make this work with karma as the runner and with jasmine as the framework. These are also what the CLI is working with. I also have a Wallaby runner, which is cool BTW. I don;t think there is anything wrong with suggesting a set of tools for people to use. In fact, I think most folks just want to know a combination that works so they can grab them and go. With that in mind, I lean towards having the guide indicate we suggest Karma and Jasmine, and here is more info (link to examples) on how to do so. But we love Mocha too ( mocha is my preference ), and we will add more on Mocha later. |
Yes, I would simply tone down this one. Instead of "Use foo", "We recommend foo". |
With the new terminology in the guide, this would be
|
To be discussed.
// cc @johnpapa @wardbell
Use Jasmine for unit testing.
Why?: It is well supported and popular in the JavaScript community.
Why?: It is widely popular in the Angular community. Jasmine is used for testing both AngularJS 1.x and Angular 2.
Why?: It has up-to-date type definitions so you can have great development experience using TypeScript.
Use Karma as test runner.
Place integration tests and tests that cover multiple code units into a separate
tests
directory in your project's root.Use protractor for End-to-End testing.
Why?: It provides high-level API on top of the Selenium WebDriver and is supported by the Angular core team.
Name the End-to-End test files using the following convention:
NAME_OF_THE_TESTED_UNIT.e2e.EXT
.The text was updated successfully, but these errors were encountered: