diff options
author | go2null <1t1is2@gmail.com> | 2016-07-08 07:11:23 -0400 |
---|---|---|
committer | go2null <(none)> | 2016-08-22 11:27:22 -0400 |
commit | 90fbae6acc9aadc9480c9e7d40589f50ec1aa14e (patch) | |
tree | 4c2d61f8a2cbb2595f84488940e7889bb54e3ad4 | |
parent | 9c4c2126b1506e2d26107c802a5abba1e6cba886 (diff) | |
download | rails-90fbae6acc9aadc9480c9e7d40589f50ec1aa14e.tar.gz rails-90fbae6acc9aadc9480c9e7d40589f50ec1aa14e.tar.bz2 rails-90fbae6acc9aadc9480c9e7d40589f50ec1aa14e.zip |
Clearly state purpose of test directories
* Added location for route, view and job tests to section 2.1. (They are currently only defined in sections 8 Testing Views and 11 Testing Jobs.)
* Added location for route test in section 7 Testing Routes. (Currently only defined in section 8 Testing Views.)
-rw-r--r-- | guides/source/testing.md | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/guides/source/testing.md b/guides/source/testing.md index e8dc6ffe2a..53e425a305 100644 --- a/guides/source/testing.md +++ b/guides/source/testing.md @@ -37,10 +37,12 @@ controllers/ helpers/ mailers/ test_helper.rb fixtures/ integration/ models/ ``` -The `models` directory is meant to hold tests for your models, the `controllers` directory is meant to hold tests for your controllers and the `integration` directory is meant to hold tests that involve any number of controllers interacting. There is also a directory for testing your mailers and one for testing view helpers. +The `helpers`, `mailers`, and `models` directories are meant to hold tests for view helpers, mailers, and models, respectively. The `controllers` directory is meant to hold tests for controllers, routes, and views. The `integration` directory is meant to hold tests for interactions between controllers. Fixtures are a way of organizing test data; they reside in the `fixtures` directory. +A `jobs` directory will also be created when an associated test is first generated. + The `test_helper.rb` file holds the default configuration for your tests. @@ -1072,7 +1074,7 @@ end Testing Routes -------------- -Like everything else in your Rails application, you can test your routes. +Like everything else in your Rails application, you can test your routes. Route tests reside in `test/controllers/` or are part of controller tests. NOTE: If your application has complex routes, Rails provides a number of useful helpers to test them. |