title: ActiveRecord::Base.send(:descendants) doesn't return all models unless touched
body: <p><strong><em>Update:</em></strong> <em>This problem no longer exists in Rails 3.2</em></p>
  
  <p>I am trying to get an array containing all the models in my rails 3 application. I am trying:</p>
  
  <pre><code>ActiveRecord::Base.send(:descendants)
  </code></pre>
  
  <p>for the same. A similar discussion happened in the question: <a href="https://stackoverflow.com/questions/516579/is-there-a-way-to-get-a-collection-of-all-the-models-in-your-rails-app">Is there a way to get a collection of all the Models in your Rails app?</a>. As pointed out in one of the answers, we need to touch the models for the models to show up. That is precisely the problem I am facing.</p>
  
  <p>There are more than a dozen models in my rails app, but </p>
  
  <pre><code>ActiveRecord::Base.send(:descendants) 
  </code></pre>
  
  <p>returns an array of size two. The array has just User and  ActiveRecord::SessionStore::Session models. I don't get the other models untill I touch the model by touching, say invoking <code>Comment.new</code>
  How can I get all the models listed without touching all the models?</p>
  
  <p>Another additional piece of information that might be useful is that I am using devise for authentication. Maybe devise is doing things in a desired way as far as User model is concerned and I am not doing those things with the other models.</p>
  
  <p>Thanks a lot in advance.</p>