Sha256: 49da4f7ac72a663cc9b06a08e116643b78476190e3658393268361e34cf8da7c
Contents?: true
Size: 465 Bytes
Versions: 2
Compression:
Stored size: 465 Bytes
Contents
require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths")) #FIXME GC 04/09/2010 - Should match either a digit or a valid label Then(/^(.+?) should match route \/(.+?)$/) do |page, route| regexp = route.gsub(/:(\w*?)id/,'(?:\d+|[A-Za-z0-9_-]+)') path_to(page).should =~ /#{regexp}/ end When(/^I go to (.+)$/) do |page| visit path_to(page) end Then(/^I should be at (.+)$/) do |page| request.path.should =~ /#{path_to(page)}/ end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
pickle-dupe-0.3.1 | features/step_definitions/path_steps.rb |
pickle-dupe-0.3.0 | features/step_definitions/path_steps.rb |