frameworks-capybara 0.0.10 → 0.0.11

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -4,7 +4,7 @@ Gem to simplify the configuration of Capybara when using multiple drivers, also
4
4
 
5
5
  Although utilising Capybara's API to run tests is extremely simple the configuration and setup of the tool can be a little confusing, particularly if you want to avoid ending up with a spaghetti like env.rb file
6
6
 
7
- The principle behind this gem is to factor out all the common setup code for registering Capybara drivers and allow the user to pass all configuration options through Cucumber's command line interface (and typically using cucumber.yml to make this even easier).
7
+ The principle behind this gem is to factor out all the common setup code for registering Capybara drivers and allow the user to pass all configuration options through Cucumber's command line interface (typically using cucumber.yml to make this easier).
8
8
 
9
9
  Below are the current drivers that can be registered:
10
10
 
@@ -17,7 +17,7 @@ Below are the current drivers that can be registered:
17
17
 
18
18
  To be added in the near future:
19
19
 
20
- * Mechanize-Caybara: There is a Caybara driver for mechanize which has recent;y surfaced on Github. Many people still enjoy using Mechanize as despite its lack of support for Javascrit, it offers a much faster 'headless' option over Celerity. Once we have tested this driver and checked its robustness we will add an option to use it via this gem.
20
+ * Mechanize-Caybara: There is a Caybara driver for mechanize which has recently surfaced on Github. Many people still enjoy using Mechanize as despite its lack of support for Javascrit, it offers a much faster 'headless' option over Celerity. Once we have tested this driver and checked its robustness we will add an option to use it via this gem.
21
21
 
22
22
  How to use this gem in your project:
23
23
 
@@ -29,12 +29,39 @@ The following environment variables can be set to configure your tests:
29
29
 
30
30
  ENVIRONMENT - this must be one of either 'sandbox', 'int', 'test', 'stage', 'live'
31
31
  BROWSER - this must be one of either 'ie', 'firefox', 'chrome', 'headless', 'remote'
32
- PROXY_URL - url of proxy if required e.g. 'http://proxyhost:80'
32
+ PROXY_URL - url of proxy if required e.g. 'http://proxyhost:80', when running a headless browser this sets the proxy for the browser itself, when running a remote browser this sets the proxy for the client which will connect to the remote selenium server
33
33
  PLATFORM - used when specifying remote test on a grid that provides a choice of platforms, this must be one of either 'WINDOWS' or 'LINUX'
34
34
  REMOTE_BROWSER - used when specifying remote test, must be one of either 'ie', 'firefox', 'chrome', 'headless', 'remote'
35
- REMOTE_BROWSER_PROXY - used when specifying remote test, sets proxy on remote browser (Firefox only at present, other browsers must have proxies set appropriately on remote machine)
35
+ REMOTE_BROWSER_PROXY_URL - used when specifying remote test, sets proxy on remote browser (Firefox only at present, other browsers must have proxies set appropriately on remote machine)
36
+ REMOTE_BROWSER_VERSION - used when specifying remote test on a grid the provides a choice of browser versions for a given browser
36
37
  REMOTE_URL - URL of remote Selenium-Webdriver server e.g. http://yourremotehost:4444/wd/hub
37
38
  FIREFOX_PROFILE - specify a firefox profile to use when running in-browser tests (local or remote)
39
+ CELERITY_JS_ENABLED (string - 'true', 'false') - determines whether Celerity (HTMLUnit) attempts to execute javascript
40
+
41
+ Here is a sample cucumber.yml:
42
+
43
+ <%intenv='ENVIRONMENT=int'%>
44
+ <%testenv='ENVIRONMENT=test'%>
45
+ <%stageenv='ENVIRONMENT=stage'%>
46
+ <%liveenv='ENVIRONMENT=live'%>
47
+ <%sandboxenv='ENVIRONMENT=sandbox'%>
48
+ <%browser_headless='BROWSER=headless'%>
49
+ <%browser_ie='BROWSER=ie'%>
50
+ <%browser_firefox='BROWSER=firefox'%>
51
+ <%browser_chrome='BROWSER=chrome'%>
52
+ <%browser_remote='BROWSER=remote'%>
53
+ <%proxy_on='PROXY_URL=http://proxyhost:proxyport'%>
54
+ <%sauce_remote_url='REMOTE_URL=http://mykey@ondemand.saucelabs.com:80/wd/hub'%>
55
+ <%demo_feature='features/demo.feature'%>
56
+
57
+ firefox-local: <%=browser_firefox%> <%=testenv%> FIREFOX_PROFILE=default <%=no_stage_tests%> <%=no_xhtml_tests%> <%=demo_feature%>
58
+ chrome-local: <%=browser_chrome%> <%=testenv%> <%=no_stage_tests%> <%=no_xhtml_tests%> <%=demo_feature%>
59
+ ie-local: <%=browser_ie%> <%=testenv%> <%=no_stage_tests%> <%=no_xhtml_tests%> <%=demo_feature%>
60
+ headless-local-proxy: <%=browser_headless%> <%=testenv%> <%=proxy_on%> <%=no_stage_tests%> <%=no_xhtml_tests%> <%=demo_feature%>
61
+ headless-local-noproxy: <%=browser_headless%> <%=testenv%> <%=no_stage_tests%> <%=no_xhtml_tests%> <%=demo_feature%>
62
+ saucelabs-proxy: <%=browser_remote%> <%=testenv%> <%=proxy_on%> FIREFOX_PROFILE=default PLATFORM=WINDOWS <%=sauce_remote_url%> <%=no_stage_tests%> <%=no_xhtml_tests%> REMOTE_BROWSER=firefox <%=demo_feature%>
63
+ saucelabs-noproxy: <%=browser_remote%> <%=testenv%> FIREFOX_PROFILE=default PLATFORM=WINDOWS <%=sauce_remote_url%> <%=no_stage_tests%> <%=no_xhtml_tests%> REMOTE_BROWSER=firefox <%=demo_feature%>
64
+
38
65
 
39
66
  This gem also sets up a number of 'base urls' for you to use in your tests, these are set based on the ENVIRONMENT variable you set when running cucumber tests (either from the comand line or in cucumber.yml), the following URLs are set:
40
67
 
@@ -54,6 +81,5 @@ This gem also sets up a number of 'base urls' for you to use in your tests, thes
54
81
 
55
82
  == Copyright
56
83
 
57
- Copyright (c) 2011 mcrmfc. See LICENSE.txt for
58
- further details.
84
+ See LICENSE.txt for further details.
59
85
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.10
1
+ 0.0.11
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{frameworks-capybara}
8
- s.version = "0.0.10"
8
+ s.version = "0.0.11"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["mcrmfc"]
12
- s.date = %q{2011-03-17}
12
+ s.date = %q{2011-03-18}
13
13
  s.description = %q{gem ti aid setup of Capybara for testing bbc sites}
14
14
  s.email = %q{mcrobbins@gmail.com}
15
15
  s.extra_rdoc_files = [
@@ -34,7 +34,7 @@ Gem::Specification.new do |s|
34
34
  s.homepage = %q{http://github.com/mcrmfc/frameworks-capybara}
35
35
  s.licenses = ["MIT"]
36
36
  s.require_paths = ["lib"]
37
- s.rubygems_version = %q{1.4.2}
37
+ s.rubygems_version = %q{1.6.0}
38
38
  s.summary = %q{gem to aid setup of Capybara for testing bbc sites}
39
39
  s.test_files = [
40
40
  "test/helper.rb",
@@ -10,7 +10,7 @@ class CapybaraSetup
10
10
 
11
11
  def initialize
12
12
 
13
- capybara_opts = {:environment => ENV['ENVIRONMENT'], :proxy => ENV['PROXY_URL'], :remote_browser_proxy_url => ENV['REMOTE_BROWSER_PROXY'], :platform => ENV['PLATFORM'], :browser_name => ENV['REMOTE_BROWSER'], :version => ENV['BROWSER_VERSION'], :url => ENV['REMOTE_URL'], :profile => ENV['FIREFOX_PROFILE'], :browser => ENV['BROWSER'].intern, :javascript_enabled => ENV['CELERITY_JS_ENABLED']}
13
+ capybara_opts = {:environment => ENV['ENVIRONMENT'], :proxy => ENV['PROXY_URL'], :remote_browser_proxy_url => ENV['REMOTE_BROWSER_PROXY_URL'], :platform => ENV['PLATFORM'], :browser_name => ENV['REMOTE_BROWSER'], :version => ENV['REMOTE_BROWSER_VERSION'], :url => ENV['REMOTE_URL'], :profile => ENV['FIREFOX_PROFILE'], :browser => ENV['BROWSER'].intern, :javascript_enabled => ENV['CELERITY_JS_ENABLED']}
14
14
 
15
15
  #validate environment variables set using cucumber.yml or passed via command line
16
16
  validate_env_vars(capybara_opts)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: frameworks-capybara
3
3
  version: !ruby/object:Gem::Version
4
- hash: 11
4
+ hash: 9
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 10
10
- version: 0.0.10
9
+ - 11
10
+ version: 0.0.11
11
11
  platform: ruby
12
12
  authors:
13
13
  - mcrmfc
@@ -15,12 +15,12 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-03-17 00:00:00 +00:00
18
+ date: 2011-03-18 00:00:00 +00:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
22
  type: :development
23
- version_requirements: &id001 !ruby/object:Gem::Requirement
23
+ requirement: &id001 !ruby/object:Gem::Requirement
24
24
  none: false
25
25
  requirements:
26
26
  - - ">="
@@ -29,12 +29,12 @@ dependencies:
29
29
  segments:
30
30
  - 0
31
31
  version: "0"
32
- requirement: *id001
33
- prerelease: false
32
+ version_requirements: *id001
34
33
  name: shoulda
34
+ prerelease: false
35
35
  - !ruby/object:Gem::Dependency
36
36
  type: :development
37
- version_requirements: &id002 !ruby/object:Gem::Requirement
37
+ requirement: &id002 !ruby/object:Gem::Requirement
38
38
  none: false
39
39
  requirements:
40
40
  - - ~>
@@ -45,12 +45,12 @@ dependencies:
45
45
  - 0
46
46
  - 0
47
47
  version: 1.0.0
48
- requirement: *id002
49
- prerelease: false
48
+ version_requirements: *id002
50
49
  name: bundler
50
+ prerelease: false
51
51
  - !ruby/object:Gem::Dependency
52
52
  type: :development
53
- version_requirements: &id003 !ruby/object:Gem::Requirement
53
+ requirement: &id003 !ruby/object:Gem::Requirement
54
54
  none: false
55
55
  requirements:
56
56
  - - ~>
@@ -61,12 +61,12 @@ dependencies:
61
61
  - 5
62
62
  - 2
63
63
  version: 1.5.2
64
- requirement: *id003
65
- prerelease: false
64
+ version_requirements: *id003
66
65
  name: jeweler
66
+ prerelease: false
67
67
  - !ruby/object:Gem::Dependency
68
68
  type: :development
69
- version_requirements: &id004 !ruby/object:Gem::Requirement
69
+ requirement: &id004 !ruby/object:Gem::Requirement
70
70
  none: false
71
71
  requirements:
72
72
  - - ">="
@@ -75,12 +75,12 @@ dependencies:
75
75
  segments:
76
76
  - 0
77
77
  version: "0"
78
- requirement: *id004
79
- prerelease: false
78
+ version_requirements: *id004
80
79
  name: rcov
80
+ prerelease: false
81
81
  - !ruby/object:Gem::Dependency
82
82
  type: :runtime
83
- version_requirements: &id005 !ruby/object:Gem::Requirement
83
+ requirement: &id005 !ruby/object:Gem::Requirement
84
84
  none: false
85
85
  requirements:
86
86
  - - ">="
@@ -89,9 +89,9 @@ dependencies:
89
89
  segments:
90
90
  - 0
91
91
  version: "0"
92
- requirement: *id005
93
- prerelease: false
92
+ version_requirements: *id005
94
93
  name: capybara
94
+ prerelease: false
95
95
  description: gem ti aid setup of Capybara for testing bbc sites
96
96
  email: mcrobbins@gmail.com
97
97
  executables: []
@@ -145,7 +145,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
145
145
  requirements: []
146
146
 
147
147
  rubyforge_project:
148
- rubygems_version: 1.4.2
148
+ rubygems_version: 1.6.0
149
149
  signing_key:
150
150
  specification_version: 3
151
151
  summary: gem to aid setup of Capybara for testing bbc sites