Sha256: c0c1ec43a06e6dd2a7aca7b6083122e9e56fa31ea591d1c80b7b51b7b4a9a11e
Contents?: true
Size: 759 Bytes
Versions: 108
Compression:
Stored size: 759 Bytes
Contents
module NavigationHelpers # Maps a name to a path. Used by the # # When /^I go to (.+)$/ do |page_name| # # step definition in webrat_steps.rb # def path_to(page_name) case page_name when /the homepage/ '/' when /the public feed index/ feeds_path when /the feed admin page/ admin_feeds_path when /the visit resource page/ visit_path(Entry.first) # Add more mappings here. # Here is a more fancy example: # # when /^(.*)'s profile page$/i # user_profile_path(User.find_by_login($1)) else raise "Can't find mapping from \"#{page_name}\" to a path.\n" + "Now, go and add a mapping in #{__FILE__}" end end end World(NavigationHelpers)
Version data entries
108 entries across 108 versions & 3 rubygems