blowmage / minitest-rails-capybara

Capybara integration for MiniTest::Rails
http://blowmage.com/minitest-rails-capybara
MIT License
131 stars 40 forks source link

Shouldn't need to end feature names in "Feature Test" #10

Closed thegrubbsian closed 11 years ago

thegrubbsian commented 11 years ago

Wouldn't it be better just to just switch into Capybara mode based on a directory? Basing it on the name of the test is not intuitive at all.

zenspider commented 11 years ago

I can say the same thing about directory. Why should a test framework have to know where a test was defined? Why should it be confined to a filesystem at all? I'd much rather see something simpler:

# ...
def self.feature desc, &b
 describe "#{desc} Feature Test", &b
end
rthbound commented 11 years ago

:+1: @thegrubbsian & @zenspider

I'm not sure why the coupling is there in the first place.. I'd prefer to pass a string of my choosing, e.g.

feature "rejects unauthorized access attempts" do
  scenario "rejected when not authorized for this reason" do
    #...
  end

  scenario "rejected when not authorized for that reason" do
    #...
  end

  scenario "rejected when not authorized for the other reason" do
    #...
  end
end
blowmage commented 11 years ago

Closed in fac9eeab20778e9caef2858c95bfd19fc0714ec6.