aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/testing.textile
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2011-01-20 10:33:38 +0100
committerXavier Noria <fxn@hashref.com>2011-01-20 10:33:38 +0100
commit236f1f52cdcb695ee42ec1ad384fc9bee643f435 (patch)
treed618fb10c41909f826b57e8a0589ed442d186f5a /railties/guides/source/testing.textile
parenta282301a77288252d135855d088f20de2397998e (diff)
parent94e0f1db1cf17aa86fed5d7dad50f9e82238900a (diff)
downloadrails-236f1f52cdcb695ee42ec1ad384fc9bee643f435.tar.gz
rails-236f1f52cdcb695ee42ec1ad384fc9bee643f435.tar.bz2
rails-236f1f52cdcb695ee42ec1ad384fc9bee643f435.zip
Merge branch 'master' of git://github.com/lifo/docrails
Diffstat (limited to 'railties/guides/source/testing.textile')
-rw-r--r--railties/guides/source/testing.textile12
1 files changed, 6 insertions, 6 deletions
diff --git a/railties/guides/source/testing.textile b/railties/guides/source/testing.textile
index 733c8a755e..5f0889f406 100644
--- a/railties/guides/source/testing.textile
+++ b/railties/guides/source/testing.textile
@@ -229,13 +229,13 @@ $ rake db:test:load
Above +rake db:migrate+ runs any pending migrations on the _development_ environment and updates +db/schema.rb+. +rake db:test:load+ recreates the test database from the current +db/schema.rb+. On subsequent attempts, it is a good idea to first run +db:test:prepare+, as it first checks for pending migrations and warns you appropriately.
-NOTE: +db:test:prepare+ will fail with an error if +db/schema.rb+ doesn't exists.
+NOTE: +db:test:prepare+ will fail with an error if +db/schema.rb+ doesn't exist.
h5. Rake Tasks for Preparing your Application for Testing
|_.Tasks |_.Description|
|+rake db:test:clone+ |Recreate the test database from the current environment's database schema|
-|+rake db:test:clone_structure+ |Recreate the test databases from the development structure|
+|+rake db:test:clone_structure+ |Recreate the test database from the development structure|
|+rake db:test:load+ |Recreate the test database from the current +schema.rb+|
|+rake db:test:prepare+ |Check for pending migrations and load the test schema|
|+rake db:test:purge+ |Empty the test database.|
@@ -512,12 +512,12 @@ After a request has been made by using one of the 5 methods (+get+, +post+, etc.
As is the case with normal Hash objects, you can access the values by referencing the keys by string. You can also reference them by symbol name, except for +assigns+. For example:
<ruby>
- flash["gordon"] flash[:gordon]
- session["shmession"] session[:shmession]
- cookies["are_good_for_u"] cookies[:are_good_for_u]
+flash["gordon"] flash[:gordon]
+session["shmession"] session[:shmession]
+cookies["are_good_for_u"] cookies[:are_good_for_u]
# Because you can't use assigns[:something] for historical reasons:
- assigns["something"] assigns(:something)
+assigns["something"] assigns(:something)
</ruby>
h4. Instance Variables Available