Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 647407e

Browse files
committed
docs(tutorial/2 - Angular Templates): Update docs for running the unit test
Update docs for running the unit test using karma. Explain some extra configuration to make if user only has one browser either Chrome of Firefox.
1 parent abc3393 commit 647407e

File tree

1 file changed

+20
-5
lines changed

1 file changed

+20
-5
lines changed

docs/content/tutorial/step_02.ngdoc

+20-5
Original file line numberDiff line numberDiff line change
@@ -195,13 +195,28 @@ to ensure that Karma and its necessary plugins are installed. You can do this by
195195

196196
To run the tests, and then watch the files for changes: `npm test`.
197197

198-
* Karma will start new instances of Chrome and Firefox browser automatically. Just ignore them and let them run in
198+
* Karma will start new instances of Chrome and Firefox browsers automatically. Just ignore them and let them run in
199199
the background. Karma will use these browsers for test execution.
200-
* If you only have Chrome browser installed on your machine, make sure to update the karma configuration file before
201-
running the test. Update `unit/test/karma.conf.js` file to only include Chrome browser:
202-
200+
* If you only have one browser installed on your machine (either Chrome or Firefox browser), make sure to update the
201+
karma configuration file before running the test. Locate the configuration file in `test/karma.conf.js`, then
202+
update the property of `browsers` to suit with the one you have in your machine.
203+
204+
If you only have Chrome browser installed:
205+
<pre>
206+
...
207+
frameworks: ['jasmine'],
208+
209+
browsers: ['Chrome'],
210+
...
211+
</pre>
212+
213+
Or if you only have Firefox browser installed:
203214
<pre>
204-
browsers: ['Chrome']
215+
...
216+
frameworks: ['jasmine'],
217+
218+
browsers: ['Firefox'],
219+
...
205220
</pre>
206221

207222
* You should see the following or similar output in the terminal:

0 commit comments

Comments
 (0)