testcentricity_web 0.3.7 → 0.3.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +47 -1
- data/lib/testcentricity_web/browser_helper.rb +14 -6
- data/lib/testcentricity_web/version.rb +1 -1
- data/testcentricity_web.gemspec +7 -3
- metadata +18 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4a0349a04f8cbc83315ce2820d10334c013c4e39
|
4
|
+
data.tar.gz: 160044d07cd07ead7a039e37625dda387dfe4f2f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 553e6ffc2d902d9090a234f96fc2586de351c61279762f2e153f972e52b4bf43db5723535b7c7929514b5ec90e91bedc5053a2e9a7a02cb063d3e68764b17a98
|
7
|
+
data.tar.gz: 9a7ce9d2b3673855ffebe13bd772d6b0a231ab6f16819dd51cc5de344eb89a1804ab7392f40ddc857e36693cc7a333f9daa8d7487bb044ea9c33e1c38d91a23b
|
data/README.md
CHANGED
@@ -1,6 +1,10 @@
|
|
1
1
|
# TestcentricityWeb
|
2
2
|
|
3
|
-
|
3
|
+
The TestCentricity™ core generic framework for desktop and responsive mobile web site testing implements a
|
4
|
+
Page Object and Data Object Model DSL, for use with Capybara. It supports testing against locally hosted
|
5
|
+
desktop browsers (Firefox, Chrome, Safari, IE, or Edge), locally hosted emulated mobile browsers (using
|
6
|
+
Firefox), or on cloud hosted browsers using the BrowserStack, Sauce Labs, or CrossBrowserTesting services.
|
7
|
+
|
4
8
|
|
5
9
|
## Installation
|
6
10
|
|
@@ -16,6 +20,48 @@ Or install it yourself as:
|
|
16
20
|
|
17
21
|
$ gem install testcentricity_web
|
18
22
|
|
23
|
+
|
24
|
+
## Setup
|
25
|
+
|
26
|
+
If you are using Cucumber, you must require the following in your env.rb file:
|
27
|
+
|
28
|
+
require 'capybara/cucumber'
|
29
|
+
require 'test/unit'
|
30
|
+
require 'testcentricity_web'
|
31
|
+
|
32
|
+
|
19
33
|
## Usage
|
20
34
|
|
21
35
|
TODO: Write usage instructions here
|
36
|
+
|
37
|
+
|
38
|
+
## Copyright
|
39
|
+
|
40
|
+
TestCentricity (tm) Framework is Copyright (c) 2014-2016, Tony Mrozinski.
|
41
|
+
All rights reserved.
|
42
|
+
|
43
|
+
|
44
|
+
Redistribution and use in source and binary forms, with or without
|
45
|
+
modification, are permitted provided that the following conditions are met:
|
46
|
+
|
47
|
+
1. Redistributions of source code must retain the above copyright notice,
|
48
|
+
this list of conditions and the following disclaimer.
|
49
|
+
|
50
|
+
2. Redistributions in binary form must reproduce the above copyright
|
51
|
+
notice, this list of conditions and the following disclaimer in the
|
52
|
+
documentation and/or other materials provided with the distribution.
|
53
|
+
|
54
|
+
3. Neither the name of the copyright holder nor the names of its contributors
|
55
|
+
may be used to endorse or promote products derived from this software without
|
56
|
+
specific prior written permission.
|
57
|
+
|
58
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
59
|
+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
60
|
+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
61
|
+
IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
62
|
+
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
63
|
+
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
|
64
|
+
OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
|
65
|
+
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
66
|
+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
67
|
+
POSSIBILITY OF SUCH DAMAGE.
|
@@ -2,24 +2,32 @@ module TestCentricity
|
|
2
2
|
module Browsers
|
3
3
|
include Capybara::DSL
|
4
4
|
|
5
|
-
#
|
5
|
+
# Sets the size of the selenium browser window.
|
6
6
|
#
|
7
|
-
#
|
8
|
-
#
|
9
|
-
#
|
10
|
-
# set_browser_window_size(1250, 800) if Capybara.current_driver == :selenium
|
11
|
-
# end
|
7
|
+
# @param resolution [Array] the desired [width, height]
|
8
|
+
# @example
|
9
|
+
# Browsers.set_browser_window_size(1024, 768)
|
12
10
|
#
|
13
11
|
def self.set_browser_window_size(resolution)
|
14
12
|
window = Capybara.current_session.driver.browser.manage.window
|
15
13
|
window.resize_to(resolution[0], resolution[1])
|
16
14
|
end
|
17
15
|
|
16
|
+
# Maximizes the selenium browser window.
|
17
|
+
#
|
18
|
+
# @example
|
19
|
+
# Browsers.maximize_browser
|
20
|
+
#
|
18
21
|
def self.maximize_browser
|
19
22
|
window = Capybara.current_session.driver.browser.manage.window
|
20
23
|
window.maximize
|
21
24
|
end
|
22
25
|
|
26
|
+
# Refreshes the selenium browser.
|
27
|
+
#
|
28
|
+
# @example
|
29
|
+
# Browsers.refresh_browser
|
30
|
+
#
|
23
31
|
def self.refresh_browser
|
24
32
|
Capybara.page.driver.browser.navigate.refresh
|
25
33
|
end
|
data/testcentricity_web.gemspec
CHANGED
@@ -10,8 +10,12 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.required_ruby_version = '>= 2.1.1'
|
11
11
|
spec.authors = ['A.J. Mrozinski']
|
12
12
|
spec.email = ['test_automation@icloud.com']
|
13
|
-
spec.summary = %q{A Page Object and Data Object Model Framework for desktop
|
14
|
-
spec.description
|
13
|
+
spec.summary = %q{A Page Object and Data Object Model Framework for desktop and responsive mobile web testing}
|
14
|
+
spec.description = %q{
|
15
|
+
TestCentricity™ core generic framework for desktop and responsive mobile web site testing implements a
|
16
|
+
Page Object and Data Object Model DSL, for use with Capybara. Supports testing against locally hosted
|
17
|
+
desktop browsers (Firefox, Chrome, Safari, IE, or Edge), locally hosted emulated mobile browsers (using
|
18
|
+
Firefox), or on cloud hosted browsers on BrowserStack, Sauce Labs, or CrossBrowserTesting.}
|
15
19
|
spec.homepage = ''
|
16
20
|
spec.license = 'BSD3'
|
17
21
|
|
@@ -23,7 +27,7 @@ Gem::Specification.new do |spec|
|
|
23
27
|
spec.add_development_dependency 'bundler', '~> 1.5'
|
24
28
|
spec.add_development_dependency 'rake'
|
25
29
|
|
26
|
-
spec.add_dependency 'capybara', '>= 2.
|
30
|
+
spec.add_dependency 'capybara', ['>= 2.1', '< 3.0']
|
27
31
|
spec.add_dependency 'rspec-expectations'
|
28
32
|
spec.add_dependency 'rspec'
|
29
33
|
spec.add_dependency 'test-unit'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: testcentricity_web
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- A.J. Mrozinski
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -44,14 +44,20 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '2.
|
47
|
+
version: '2.1'
|
48
|
+
- - "<"
|
49
|
+
- !ruby/object:Gem::Version
|
50
|
+
version: '3.0'
|
48
51
|
type: :runtime
|
49
52
|
prerelease: false
|
50
53
|
version_requirements: !ruby/object:Gem::Requirement
|
51
54
|
requirements:
|
52
55
|
- - ">="
|
53
56
|
- !ruby/object:Gem::Version
|
54
|
-
version: '2.
|
57
|
+
version: '2.1'
|
58
|
+
- - "<"
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: '3.0'
|
55
61
|
- !ruby/object:Gem::Dependency
|
56
62
|
name: rspec-expectations
|
57
63
|
requirement: !ruby/object:Gem::Requirement
|
@@ -150,8 +156,12 @@ dependencies:
|
|
150
156
|
- - ">="
|
151
157
|
- !ruby/object:Gem::Version
|
152
158
|
version: 2.50.0
|
153
|
-
description:
|
154
|
-
|
159
|
+
description: |2-
|
160
|
+
|
161
|
+
TestCentricity™ core generic framework for desktop and responsive mobile web site testing implements a
|
162
|
+
Page Object and Data Object Model DSL, for use with Capybara. Supports testing against locally hosted
|
163
|
+
desktop browsers (Firefox, Chrome, Safari, IE, or Edge), locally hosted emulated mobile browsers (using
|
164
|
+
Firefox), or on cloud hosted browsers on BrowserStack, Sauce Labs, or CrossBrowserTesting.
|
155
165
|
email:
|
156
166
|
- test_automation@icloud.com
|
157
167
|
executables: []
|
@@ -208,7 +218,7 @@ rubyforge_project:
|
|
208
218
|
rubygems_version: 2.2.2
|
209
219
|
signing_key:
|
210
220
|
specification_version: 4
|
211
|
-
summary: A Page Object and Data Object Model Framework for desktop
|
212
|
-
testing
|
221
|
+
summary: A Page Object and Data Object Model Framework for desktop and responsive
|
222
|
+
mobile web testing
|
213
223
|
test_files: []
|
214
224
|
has_rdoc:
|