obrok / futile

lightweight functional/blackbox/acceptance testing package for web pages
8 stars 0 forks source link

Session#follow_redirect #4

Closed michalbugno closed 14 years ago

michalbugno commented 15 years ago

It should use Futile's api (Session#get / Session#request) instead call session directly -- this way we make sure the state of class is consistent. But this requires refactoring to prevent stack overflow (currently #follow_redirect is called from within #request)

michalbugno commented 15 years ago
def test_redirection_sets_correct_uri
  @futile.get("/single_redirect")
  assert_equal "/simple_get", @futile.path
end

This test proves that @uri is not set correctly when following redirect

michalbugno commented 14 years ago

Tested on "gogle.pl" which redirects to "google.pl", works, #full_path shows "google.pl/"