diff options
author | Viktor Fonic <viktor.fonic@gmail.com> | 2018-05-13 21:37:44 +0200 |
---|---|---|
committer | Robin Dupret <robin.dupret@gmail.com> | 2018-11-09 14:31:02 +0100 |
commit | a6b0c4a2d2fd466c99de483ee3a3396bc270e9a7 (patch) | |
tree | 5ba15ec85fa75c4ce169ed9c4381a76d0b01ff6e /guides/source/contributing_to_ruby_on_rails.md | |
parent | d80925b169f0db950697868f5659a67cc03e8654 (diff) | |
download | rails-a6b0c4a2d2fd466c99de483ee3a3396bc270e9a7.tar.gz rails-a6b0c4a2d2fd466c99de483ee3a3396bc270e9a7.tar.bz2 rails-a6b0c4a2d2fd466c99de483ee3a3396bc270e9a7.zip |
Docs: Update Development Dependencies Install
* Move all the testing related stuff to the contributing guide and
redirect the reader to this guide once the installation process
is finished as running tests is the logical next step.
* Group documentation instructions by OS, not by gem
* It eases the installation process and lessen the need to scroll
through the guide
* There's still a list of all additional services required for each
of the gems above the instructions for each OS.
* Also update a bit the instructions
* Update some package names
* Add `yarn` to the package list for Arch Linux and FreeBSD
* Use `dnf` instead of `yum` for Fedora and CentOS
* Advise the user to use `brew bundle` on macOS to lessen the
maintenance burden for this OS and ease the process for the user.
[ci skip]
Diffstat (limited to 'guides/source/contributing_to_ruby_on_rails.md')
-rw-r--r-- | guides/source/contributing_to_ruby_on_rails.md | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/guides/source/contributing_to_ruby_on_rails.md b/guides/source/contributing_to_ruby_on_rails.md index ed47a0de0f..709a5146e9 100644 --- a/guides/source/contributing_to_ruby_on_rails.md +++ b/guides/source/contributing_to_ruby_on_rails.md @@ -324,6 +324,26 @@ $ cd actionmailer $ bundle exec rake test ``` +#### For a Specific Directory + +If you want to run the tests located in a specific directory use the `TEST_DIR` +environment variable. For example, this will run the tests in the +`railties/test/generators` directory only: + +```bash +$ cd railties +$ TEST_DIR=generators bundle exec rake test +``` + +#### For a Specific File + +You can run the tests for a particular file by using: + +```bash +$ cd actionpack +$ bundle exec ruby -w -Itest test/template/form_helper_test.rb +``` + #### Running a Single Test You can run a single test through ruby. For instance: @@ -333,8 +353,7 @@ $ cd actionmailer $ bundle exec ruby -w -Itest test/mail_layout_test.rb -n test_explicit_class_layout ``` -The `-n` option allows you to run a single method instead of the whole -file. +The `-n` option allows you to run a single method instead of the whole file. #### Running tests with a specific seed |