From 2e813e9cab60f7a5c1d76f4b1ff5647500ea0418 Mon Sep 17 00:00:00 2001 From: u2ix Date: Sun, 23 Oct 2011 08:07:13 -0700 Subject: [PATCH] added a few notes for typical problems with selenium --- Testing.textile | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/Testing.textile b/Testing.textile index b9b8d76..05cfe31 100644 --- a/Testing.textile +++ b/Testing.textile @@ -77,6 +77,7 @@ RAILS_ENV=selenium cucumber -p selenium features/my_feature.feature +If you encounter problems runnig selenium tests, look at the _problems with selenium tests_ section below. h2. Running the tests headless All tests will run on a headless setup except for the selenium tests. They will need a webbrowser which will need a running X-server. @@ -115,4 +116,19 @@ in a separate command window, then run and Firefox will pop up and run the suite. If this does not work, you can run the suite manually by launching the server in test mode with the command above, and navigating to -http://localhost:3000/selenium/ in your browser of choice. \ No newline at end of file +http://localhost:3000/selenium/ in your browser of choice. + +.h2 Problems with cucumber selenium tests +.h3 Tests doesn't start +Firefox 3.x is required to run the selenium tests properly. It's also recommanded to use an english version, to avoid problems due to the locale. +You can get an old version of firefox "here":http://www.mozilla.org/en-US/firefox/all-older.html. + +.h3 Sqlite3 Lock exceptions +In the default settings sqlite locks the db immediately. This behavior can cause problems with the fast executing online tests. Add a timeout to the database.yml configuration file to avoid these errors. +For example: +

+test: &TEST
+    adapter: sqlite3
+    database: db/test.db
+    timeout: 10000
+