2011-08-02 8 views
0

開発モードでは、私のブラウザでhttp://localhost:3000/brands/を指し示すことができ、すべてのブランドのリストが表示され、ルートマッピング、コントローラのインデックスアクションとindex.html.hamlファイルはすべて仕事をしています。開発モードで見ることができるテストモードでキュウリが見つかりません

私はrake db:test:cloneを実行したことを思い出しました。 /features/support/paths.rb

私が持っている:

def path_to(page_name) 
    case page_name 
    when /the home\s?page/ 
    '/' 
    when /the Brand\s?page/ 
    '/brands' 
end 

しかし、私はcucumber featuresを実行すると、私が手:

When I am on the Brand page # features/step_definitions/web_steps.rb:44 
No route matches "/brands" (ActionController::RoutingError) 

はどのようにこの問題の原因を見つけるに行きますか?

ありがとう、

スティーブン。

+0

あなたはすくいルートを行うことができますし、私たちに、具体的なブランドのルートに入れて出してくださいを与えますか? – jaydel

答えて

0

使用すると、URLヘルパーをレール:

when /the Brand\s?page/ 
    brands_path 
関連する問題