This project is archived and is in readonly mode.

#1825 ✓resolved

Using Fixtures docs in API RDoc needs work

Reported by smerp | January 30th, 2009 @ 04:13 AM | in 2.x

The current "Using Fixtures" documentation notes three methods of accessing fixture data from within Rails tests:

  1. By using a hash stored in an instance variable named after the fixture e.g. @blobs['foo']['name']
  2. By using an instance variable named after the record name, e.g.
  3. By using a dynamically-created object, e.g. blobs(:foo).name

However, the default has been to not instantiate instance variables, which means only method #3 will work. Furthermore, all examples don't use the test method for each test case.

Recommend moving method #3 to be the primary method, and note how to enable methods #1 and #2. Update examples to show this, using the new test methods.

Complete writeup here:

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>

People watching this ticket