title: Rails 3 trouble with namespaces & custom classes (uninitialized constant)
body: <p>I have a file in my Rails 3.2.11 project called <code>app/queries/visible_discussions.rb</code> which looks like the following:</p>
  
  <pre><code>class VisibleDiscussions
    ...
  end
  </code></pre>
  
  <p>I'd like to namespace the query so that I can call it using something like <code>Queries::VisibleDiscussions</code> so I tried to do the following:</p>
  
  <pre><code>module Queries
    class VisibleDiscussions
      ...
    end
  end
  </code></pre>
  
  <p>However, I'm getting a <code>uninitialized constant Queries (NameError)</code> when I try to call <code>Queries::VisibleDiscussions</code> from the rails console.</p>
  
  <p>Any ideas?</p>