[rspec-users] Speccing the creation of a singleton resource
nick at deadorange.com
Tue Apr 20 08:33:17 EDT 2010
Hey guys. I'm writing a Rails gem that's used by controllers. The gem
creates a singleton resource at run-time, along the lines of:
controller_name = ...dynamically generated...
ActionController::Routing::Routes.draw do |map|
map.resource controller_name, :only => :show
I'm trying to figure out how to spec the creation of the singleton
resource. The best that I've come up with so far is checking that a
However, that doesn't test whether or not it's a singleton resource.
Any suggestions? Thanks,
More information about the rspec-users