features/support/cucumber_helper.rb in rambo_ruby-0.1.0 vs features/support/cucumber_helper.rb in rambo_ruby-0.2.0

- old
+ new

@@ -1,10 +1,10 @@ module CucumberHelper def read_example(example) possible_paths = [ - File.expand_path("../examples/raml/#{example}", __FILE__), - File.expand_path("../examples/rspec/#{example}", __FILE__), - File.expand_path("../examples/rspec/#{example}", __FILE__) + File.join(CUCUMBER_DIR_ROOT, "examples/raml/#{example}"), + File.join(CUCUMBER_DIR_ROOT, "examples/rspec/#{example}"), + File.join(CUCUMBER_DIR_ROOT, "examples/rspec/#{example}") ] possible_paths.each do |path| return File.read(path) rescue next end