testcentricity_web 3.0.16 → 3.0.17
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/Gemfile.lock +2 -2
- data/lib/testcentricity_web/version.rb +1 -1
- data/lib/testcentricity_web/web_core/page_objects_helper.rb +4 -0
- data/lib/testcentricity_web/web_core/page_sections_helper.rb +4 -0
- data/lib/testcentricity_web/web_core/webdriver_helper.rb +5 -12
- data/lib/testcentricity_web/web_elements/ui_elements_helper.rb +21 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28c21dc1cccc47282ea868cf24537968b8afc5a2
|
4
|
+
data.tar.gz: fac64767a0b4ea3f9c929f502ad624637828bcb1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 83636b0f706a88718b7e688aac1bd13c16f6d5c615acc8aeaf678737a1a811bff09d0d5540ea6f3000db9f1f8e21deef18484307210d287fe9ef34bcb4cdc5dc
|
7
|
+
data.tar.gz: e119b96eaa75bda7da9d592f84bf3242c95bbd98289970fc25ba722061814702c5693e7e1011c783953c7b97067ead8b9f1d0e696e539e1294f439f20a4e7f49
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,12 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
All notable changes to this project will be documented in this file.
|
3
3
|
|
4
|
+
## [3.0.17] - 2018-09-19
|
5
|
+
|
6
|
+
### Added
|
7
|
+
* `UIElement.aria_disabled?` and `UIElement.aria_label` methods.
|
8
|
+
* Updated `PageObject.verify_ui_states` and `PageSection.verify_ui_states` methods to support verification of `aria-label` and `aria-disabled` properties.
|
9
|
+
|
4
10
|
## [3.0.16] - 2018-09-21
|
5
11
|
|
6
12
|
### Added
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
testcentricity_web (3.0.
|
4
|
+
testcentricity_web (3.0.17)
|
5
5
|
appium_lib
|
6
6
|
browserstack-local
|
7
7
|
capybara (>= 3.1, < 4)
|
@@ -28,7 +28,7 @@ GEM
|
|
28
28
|
faye-websocket (~> 0.10.0)
|
29
29
|
selenium-webdriver (~> 3.14)
|
30
30
|
browserstack-local (1.3.0)
|
31
|
-
capybara (3.8.
|
31
|
+
capybara (3.8.2)
|
32
32
|
addressable
|
33
33
|
mini_mime (>= 0.1.3)
|
34
34
|
nokogiri (~> 1.8)
|
@@ -662,6 +662,10 @@ module TestCentricity
|
|
662
662
|
actual = ui_object.count(visible = :all)
|
663
663
|
when :siebel_options
|
664
664
|
actual = ui_object.get_siebel_options
|
665
|
+
when :aria_label
|
666
|
+
actual = ui_object.aria_label
|
667
|
+
when :aria_disabled
|
668
|
+
actual = ui_object.aria_disabled?
|
665
669
|
else
|
666
670
|
if property.is_a?(Hash)
|
667
671
|
property.each do |key, value|
|
@@ -862,6 +862,10 @@ module TestCentricity
|
|
862
862
|
actual = ui_object.count(visible = :all)
|
863
863
|
when :siebel_options
|
864
864
|
actual = ui_object.get_siebel_options
|
865
|
+
when :aria_label
|
866
|
+
actual = ui_object.aria_label
|
867
|
+
when :aria_disabled
|
868
|
+
actual = ui_object.aria_disabled?
|
865
869
|
else
|
866
870
|
if property.is_a?(Hash)
|
867
871
|
property.each do |key, value|
|
@@ -204,9 +204,7 @@ module TestCentricity
|
|
204
204
|
options.args << '--headless' if browser == :firefox_headless
|
205
205
|
Capybara::Selenium::Driver.new(app, browser: :firefox, options: options)
|
206
206
|
when :chrome, :chrome_headless
|
207
|
-
(browser == :chrome) ?
|
208
|
-
options = Selenium::WebDriver::Chrome::Options.new :
|
209
|
-
options = Selenium::WebDriver::Chrome::Options.new(args: %w[headless disable-gpu no-sandbox])
|
207
|
+
options = (browser == :chrome) ? Selenium::WebDriver::Chrome::Options.new : Selenium::WebDriver::Chrome::Options.new(args: %w[headless disable-gpu no-sandbox])
|
210
208
|
options.add_argument('--disable-infobars')
|
211
209
|
options.add_argument("--lang=#{ENV['LOCALE']}") if ENV['LOCALE']
|
212
210
|
Capybara::Selenium::Driver.new(app, browser: :chrome, options: options)
|
@@ -273,9 +271,7 @@ module TestCentricity
|
|
273
271
|
capabilities['project'] = ENV['AUTOMATE_PROJECT'] if ENV['AUTOMATE_PROJECT']
|
274
272
|
capabilities['build'] = ENV['AUTOMATE_BUILD'] if ENV['AUTOMATE_BUILD']
|
275
273
|
|
276
|
-
ENV['TEST_CONTEXT'] ?
|
277
|
-
context_message = "#{Environ.test_environment} - #{ENV['TEST_CONTEXT']}" :
|
278
|
-
context_message = Environ.test_environment
|
274
|
+
context_message = ENV['TEST_CONTEXT'] ? "#{Environ.test_environment} - #{ENV['TEST_CONTEXT']}" : Environ.test_environment
|
279
275
|
if ENV['PARALLEL']
|
280
276
|
thread_num = ENV['TEST_ENV_NUMBER']
|
281
277
|
thread_num = 1 if thread_num.blank?
|
@@ -289,6 +285,7 @@ module TestCentricity
|
|
289
285
|
|
290
286
|
case browser.downcase.to_sym
|
291
287
|
when :ie
|
288
|
+
capabilities['ie.fileUploadDialogTimeout'] = 10000
|
292
289
|
capabilities['ie.ensureCleanSession'] = 'true'
|
293
290
|
capabilities['ie.browserCommandLineSwitches'] = 'true'
|
294
291
|
capabilities['nativeEvents'] = 'true'
|
@@ -418,9 +415,7 @@ module TestCentricity
|
|
418
415
|
when :firefox, :safari, :ie, :edge
|
419
416
|
capabilities = Selenium::WebDriver::Remote::Capabilities.send(browser)
|
420
417
|
when :chrome, :chrome_headless
|
421
|
-
|
422
|
-
options = %w[--disable-infobars] :
|
423
|
-
options = %w[headless disable-gpu no-sandbox --disable-infobars]
|
418
|
+
options = browser == :chrome ? %w[--disable-infobars] : %w[headless disable-gpu no-sandbox --disable-infobars]
|
424
419
|
options.push("--lang=#{ENV['LOCALE']}") if ENV['LOCALE']
|
425
420
|
capabilities = Selenium::WebDriver::Remote::Capabilities.chrome('goog:chromeOptions' => { args: options })
|
426
421
|
else
|
@@ -507,9 +502,7 @@ module TestCentricity
|
|
507
502
|
Environ.platform = :desktop
|
508
503
|
end
|
509
504
|
|
510
|
-
ENV['TUNNELING'] ?
|
511
|
-
endpoint = '@localhost:4445/wd/hub' :
|
512
|
-
endpoint = '@hub.testingbot.com:4444/wd/hub'
|
505
|
+
endpoint = ENV['TUNNELING'] ? '@localhost:4445/wd/hub' : '@hub.testingbot.com:4444/wd/hub'
|
513
506
|
endpoint = "http://#{ENV['TB_USERNAME']}:#{ENV['TB_AUTHKEY']}#{endpoint}"
|
514
507
|
Capybara.register_driver :testingbot do |app|
|
515
508
|
capabilities = Selenium::WebDriver::Remote::Capabilities.new
|
@@ -556,6 +556,27 @@ module TestCentricity
|
|
556
556
|
)
|
557
557
|
end
|
558
558
|
|
559
|
+
# Return state of UI object's aria-label property
|
560
|
+
#
|
561
|
+
# @return [String]
|
562
|
+
# @example
|
563
|
+
# buy_now_button.aria_label
|
564
|
+
#
|
565
|
+
def aria_label
|
566
|
+
get_attribute('aria-label')
|
567
|
+
end
|
568
|
+
|
569
|
+
# Return state of UI object's aria-disabled property
|
570
|
+
#
|
571
|
+
# @return [Boolean]
|
572
|
+
# @example
|
573
|
+
# buy_now_button.aria_disabled?
|
574
|
+
#
|
575
|
+
def aria_disabled?
|
576
|
+
state = get_attribute('aria-disabled')
|
577
|
+
state.boolean? ? state : state == 'true'
|
578
|
+
end
|
579
|
+
|
559
580
|
def get_attribute(attrib)
|
560
581
|
obj, type = find_element(false)
|
561
582
|
object_not_found_exception(obj, type)
|
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: 3.0.
|
4
|
+
version: 3.0.17
|
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: 2018-
|
11
|
+
date: 2018-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|