Bryan Helmkamp
3bc2d4d1b8
Merge commit 'rcarver/merb-uploads'
2009-06-14 21:18:47 -04:00
Mike Gaffney
f4141f787d
[ #261 state:awaiting-patch]
...
added a test that shows that selenium can't click a link with text that has parens in it
2009-06-08 12:08:53 -05:00
Mike Gaffney
a6a4a7cfd9
moving app server lookup out into a factory
2009-06-04 14:44:06 -05:00
Mike Gaffney
f3a12adaa9
whitespace changes
2009-06-04 12:18:31 -05:00
Thomas Jack
2ae14f78b1
expose regexp escape problem in fill_in_test
2009-06-02 17:56:12 -05:00
mike.gaffney
bd1655c8e2
[ #257 state:awaiting-patch] here is a test proving the issue
2009-06-02 17:23:12 -05:00
mike.gaffney
2219ab62d3
refactoring buttons to their own controller
2009-06-01 12:25:36 -05:00
mike.gaffney
5430930bac
added test for clicking link by title
2009-06-01 12:17:29 -05:00
Matthias Marschall
9b85b6d7e0
added integration tests for all cases of click_button (by id, by html, by value, by alt for buttons and inputs of types image, button and submit)
2009-05-29 17:05:35 -05:00
Matthias Marschall
6cd734aec9
made selenium integration tests run applying larrytheliquid's patch: 627913708c
2009-05-29 17:05:35 -05:00
Luke Amdor
7f13a70b4b
Added current_url to SeleniumSession to have the same api for both sessions
2009-05-13 22:33:20 -05:00
Bryan Helmkamp
b439d7f807
Revert "Canonicalize all URLs (Shalon Wood)"
...
This reverts commit 755cf6e508
.
2009-05-11 16:48:28 -04:00
Bryan Helmkamp
453cb4b3eb
Stripping whitespace
2009-05-11 01:27:04 -04:00
Bryan Helmkamp
b5254109f1
Start on Rack::Test integration
2009-05-11 00:12:27 -04:00
Bryan Helmkamp
755cf6e508
Canonicalize all URLs (Shalon Wood)
2009-05-11 00:12:27 -04:00
Ryan Carver
26edfbc7cb
Integration tests for Merb file uploads
2009-04-24 14:11:49 -07:00
Bryan Helmkamp
03914fd293
Whitespace
2009-04-07 20:30:12 -04:00
Simon Rozet
90baf3311c
Sinatra now provides sensible options for testing
...
In the lastest release, 0.9.1:
* Set sensible defaults on Default for test env [1]
5a33a9586f
* Set :environment to :test in TestHarness
9af37724e0
* Set :environment to :test when Sinatra::Test is included
93b19a3492
[1] Only Sinatra::Default provides special options for testing. If you subclass
Sinatra::Base, you'll have to set them yourself.
foo
2009-03-08 23:41:34 +01:00
Simon Rozet
4e07f5b654
Fix following of absolute redirect URL in Sinatra
...
What's going on when the app redirects to an absolute URL?
* Sinatra relies on Rack::MockSession which sets SERVER_NAME to
"example.org" [1] on request it makes. However, Webrat expects
it to be "www.example.com"
* In MyClassyApp, the redirect URL is made out of Rack::Request#url [2]
which uses SERVER_NAME, which is set to "example.org" by Rack::MockSession.
As a result, Webrat see it as an external redirect and don't follow it.
NOTE:
* SERVER_NAME is stricly equivalent to HTTP_HOST [3]
* This could have been fixed in Webrat::Session too. I'am not sure
that it won't affect other frameworks so I left it intact.
def request_page(url, http_method, data) #:nodoc:
h = headers
h['HTTP_REFERER'] = @current_url if @current_url
+ h['HTTP_HOST'] = 'www.example.com'
[1] 5c00dd698e/lib/rack/mock.rb (L79)
[2] 5c00dd698e/lib/rack/request.rb (L201)
[3] 5c00dd698e/lib/rack/request.rb (L72)
2009-02-28 03:30:26 +01:00
Simon Rozet
7d7c32256d
Support for "modular" Sinatra app style
...
Since Sinatra 0.9, apps can be ancapsulated in a class ("modular" style)
or be on the top level, just like before ("classic" style)
* http://wiki.github.com/brynary/webrat/sinatra
* http://www.sinatrarb.com/extensions.html
2009-02-28 03:30:25 +01:00
Bryan Helmkamp
4769a5f90b
Detect infinite redirects and raise a Webrat::InfiniteRedirectError (Daniel Lucraft)
2009-02-08 20:54:00 -05:00
Bryan Helmkamp
238bfb469e
Use redgreen when running rails integraton tests if available
2009-01-25 19:48:02 -05:00
Mike Gaffney
3d5dd1343c
turning off have_tag test for now until we figure out whether we want it or not. Making integration not run the selenium tests for now. Need a eventually framework for test::unit
2009-01-25 18:30:03 -06:00
Amos King
0a021059d6
Added to rails test for have_tag
2009-01-23 21:13:52 -06:00
Amos King
0b8e378fb2
change to use rails label tag for test.
2009-01-23 20:56:16 -06:00
Amos King
813adcc238
Remove the rails selenium test directory and change rake tasks for selenium and rails modes to run the same tests. The end goal should be that the same tests run in both Seleium and Webrat.
2009-01-23 15:37:26 -06:00
Amos King
da59584cdf
add the ability for selenium mode to create pids dirs
2009-01-23 15:34:51 -06:00
Amos King
2c9b546a83
Merge branch 'lh_120_tests_with_selenium' of git@github.com:gaffo/webrat into lh_82
...
Conflicts:
spec/integration/rails/test/integration/webrat_test.rb
2009-01-23 15:11:16 -06:00
Zach Dennis
0272e81847
Fixed issue where webrat was only using relative paths when making requests for Rails apps. This borked Rails apps that use subdomains [John Hwang/Zach Dennis]
2009-01-20 21:48:48 -05:00
Bryan Helmkamp
14d114ce1d
Ensure the previous pages params aren't passed through redirect
2009-01-19 13:56:22 -05:00
Bryan Helmkamp
6676ae2da9
Adding integration test for field_labeled
2009-01-17 17:13:20 -05:00
Bryan Helmkamp
7a7cb3f002
Support passing an ActiveRecord model to #within when in Rails mode [ #68 state:resolved] (Luke Melia)
2009-01-17 13:18:42 -05:00
Amos King
652610381a
added selenium test for assert_selector
2009-01-13 22:48:57 -06:00
Amos King
fd860a2e6d
added rails test for assert_selector
2009-01-13 22:48:06 -06:00
Amos King
a32ec70d7f
added xpath test to selenium
2009-01-13 22:45:26 -06:00
Amos King
647eb4cb6f
add test for assert_xpath
2009-01-13 22:43:31 -06:00
Amos King
2d065e8a2d
add test for click_link with id to selenium
2009-01-13 22:43:14 -06:00
Amos King
0aa5fda61d
added click link test to selenium
2009-01-13 22:35:58 -06:00
Amos King
2510e7d43d
added clicking link by id
2009-01-13 22:34:47 -06:00
Amos King
3902573d3e
add a link to the rendered text and add a test for clicking it
2009-01-13 22:33:47 -06:00
Amos King
a396758da4
fixed rakefile so the tasks will run the correct mode, and so there is a task to run both modes.
2009-01-13 07:57:20 -06:00
Mike Gaffney
758e323f89
breaking up selenium from rails_webrat tests for the moment
2009-01-13 00:26:49 -06:00
Mike Gaffney
c0220232c7
broke selenium mode tests out into a seperate file.
2009-01-13 00:13:17 -06:00
Mike Gaffney
c1b49f36ea
working on getting standardized for the specs
2009-01-12 23:31:14 -06:00
Mike Gaffney
f7f8c91cb7
getting selenium up and running
2009-01-12 22:54:33 -06:00
Mike Gaffney
f2a202ae5e
adding pids directories
2009-01-12 22:44:53 -06:00
Mike Gaffney
f835bac31b
cleaning out app and getting selenium mode to work
2009-01-12 22:42:35 -06:00
Mike Gaffney
bdf660aecb
Renamed the task for seleniumw
2009-01-12 22:30:36 -06:00
Mike Gaffney
a8a63472bc
breaking the test mode out into a specific test modes
2009-01-12 22:30:03 -06:00
Josh Knowles
9825aee47e
Don't follow external redirects
2009-01-04 23:56:52 -05:00