开发者

Rails Cucumber URL hosts

开发者 https://www.devze.com 2023-01-02 03:10 出处:网络
So... I have this URL: example.com which works in my browser, cause in开发者_Python百科 my hosts file i have it set to

So... I have this URL: example.com which works in my browser, cause in开发者_Python百科 my hosts file i have it set to

127.0.0.1   example.com

And that works in my browser... but not in cucumber.

Any ideas?


Figured it out.

needed to change The Given I am on step definition to

Given /^(?:|I )am on (.+)$/ do |page_name|
host! "cucumber.example.com"
visit path_to(page_name)
end
0

精彩评论

暂无评论...
验证码 换一张
取 消