testcentricity_web 3.0.13 → 3.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/Gemfile.lock +4 -4
- data/README.md +25 -24
- data/lib/testcentricity_web/version.rb +1 -1
- data/lib/testcentricity_web/web_core/webdriver_helper.rb +36 -0
- data/lib/testcentricity_web/web_elements/table.rb +2 -2
- metadata +2 -4
- data/.ruby-gemset +0 -1
- data/.ruby-version +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 065efc5a65b07d6384a095d926f80038f1793dda
|
4
|
+
data.tar.gz: 7b0de3bfb436068551d23134c6d14a50658ae20e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77c5c4b60f2ac9895874f84078ea77c561e50ed3541bc4c3dd2394571fc8cbc4b56d61e0f1821d036a326b37643c76012f1546d40cb8aed14bfb0250e9a2cb94
|
7
|
+
data.tar.gz: d81f96ba971e9f7bce3864996d06d10b2662fff119f7479877eb5abcc2cb5fe4f0b64157ff467853b8d308374c5b7b9f315622cd9db4ba7b8583381d23ae4d2f
|
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.14] - 2018-09-17
|
5
|
+
|
6
|
+
### Added
|
7
|
+
* Added support for performing file uploads in browsers running on remote cloud hosted services as well as in Selenium Grid and Dockerized Selenium
|
8
|
+
Grid environments.
|
9
|
+
|
4
10
|
## [3.0.13] - 2018-08-10
|
5
11
|
|
6
12
|
### Fixed
|
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.13.1)
|
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.
|
31
|
+
capybara (3.6.0)
|
32
32
|
addressable
|
33
33
|
mini_mime (>= 0.1.3)
|
34
34
|
nokogiri (~> 1.8)
|
@@ -48,7 +48,7 @@ GEM
|
|
48
48
|
ffi (1.9.25)
|
49
49
|
i18n (1.1.0)
|
50
50
|
concurrent-ruby (~> 1.0)
|
51
|
-
mini_mime (1.0.
|
51
|
+
mini_mime (1.0.1)
|
52
52
|
mini_portile2 (2.3.0)
|
53
53
|
nokogiri (1.8.4)
|
54
54
|
mini_portile2 (~> 2.3.0)
|
@@ -70,7 +70,7 @@ GEM
|
|
70
70
|
test-unit (3.2.8)
|
71
71
|
power_assert
|
72
72
|
tomlrb (1.2.7)
|
73
|
-
webdrivers (3.3.
|
73
|
+
webdrivers (3.3.3)
|
74
74
|
nokogiri (~> 1.6)
|
75
75
|
rubyzip (~> 1.0)
|
76
76
|
selenium-webdriver (~> 3.0)
|
data/README.md
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
The TestCentricity™ Web core generic framework for desktop and mobile web browser-based application testing implements a Page Object and Data
|
7
7
|
Object Model DSL for use with Cucumber, Capybara (version 3.x), and Selenium-Webdriver (version 3.x).
|
8
8
|
|
9
|
-
An example project that demonstrates the implementation of a page object model framework using Cucumber and TestCentricity™ can be found [here](https://github.com/TestCentricity/tc_web_sample)
|
9
|
+
**An example project that demonstrates the implementation of a page object model framework using Cucumber and TestCentricity™ can be found [here](https://github.com/TestCentricity/tc_web_sample).**
|
10
10
|
|
11
11
|
The TestCentricity™ Web gem supports running automated tests against the following web test targets:
|
12
12
|
* locally hosted desktop browsers (Firefox, Chrome, Safari, or IE)
|
@@ -229,15 +229,14 @@ the UI to hide implementation details, as shown below:
|
|
229
229
|
# verify Login page default UI state
|
230
230
|
def verify_page_ui
|
231
231
|
ui = {
|
232
|
-
login_button => { :
|
233
|
-
user_id_field => { :
|
234
|
-
password_field => { :
|
235
|
-
remember_checkbox => { :exists => true, :
|
236
|
-
forgot_password_link => { :
|
237
|
-
error_message_label => { :
|
232
|
+
login_button => { visible: true, caption: 'LOGIN' },
|
233
|
+
user_id_field => { visible: true, enabled: true },
|
234
|
+
password_field => { visible: true, enabled: true, value: '', placeholder: 'Password' },
|
235
|
+
remember_checkbox => { :exists => true, enabled: true, checked: false },
|
236
|
+
forgot_password_link => { visible: true, caption: 'Forgot your password?' },
|
237
|
+
error_message_label => { visible: false }
|
238
238
|
}
|
239
239
|
verify_ui_states(ui)
|
240
|
-
super
|
241
240
|
end
|
242
241
|
end
|
243
242
|
|
@@ -537,27 +536,29 @@ to be instantiated by **PageManager**:
|
|
537
536
|
|
538
537
|
module WorldPages
|
539
538
|
def page_objects
|
540
|
-
{
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
|
539
|
+
{
|
540
|
+
login_page: LoginPage,
|
541
|
+
home_page: HomePage,
|
542
|
+
registration_page: RegistrationPage,
|
543
|
+
search_results_page: SearchResultsPage,
|
544
|
+
products_grid_page: ProductsCollectionPage,
|
545
|
+
product_detail_page: ProductDetailPage,
|
546
|
+
shopping_basket_page: ShoppingBasketPage,
|
547
|
+
payment_method_page: PaymentMethodPage,
|
548
|
+
confirm_purchase_page: PurchaseConfirmationPage,
|
549
|
+
my_account_page: MyAccountPage,
|
550
|
+
my_order_history_page: MyOrderHistoryPage,
|
551
|
+
my_ship_to_addresses_page: MyShipToAddressesPage,
|
552
|
+
terms_conditions_page: TermsConditionsPage,
|
553
|
+
privacy_policy_page: PrivacyPolicyPage,
|
554
|
+
faqs_page: FAQsPage,
|
555
|
+
contact_us_page: ContactUsPage
|
556
556
|
}
|
557
557
|
end
|
558
558
|
end
|
559
559
|
|
560
560
|
World(WorldPages)
|
561
|
+
|
561
562
|
|
562
563
|
The `WorldPages` module above should be defined in the `world_pages.rb` file in the `features/support` folder.
|
563
564
|
|
@@ -322,6 +322,12 @@ module TestCentricity
|
|
322
322
|
|
323
323
|
Capybara.default_driver = :browserstack
|
324
324
|
Capybara.run_server = false
|
325
|
+
# configure file_detector for remote uploads
|
326
|
+
selenium = Capybara.page.driver.browser
|
327
|
+
selenium.file_detector = lambda do |args|
|
328
|
+
str = args.first.to_s
|
329
|
+
str if File.exist?(str)
|
330
|
+
end
|
325
331
|
end
|
326
332
|
|
327
333
|
def self.initialize_crossbrowser
|
@@ -358,6 +364,12 @@ module TestCentricity
|
|
358
364
|
|
359
365
|
Capybara.default_driver = :crossbrowser
|
360
366
|
Capybara.run_server = false
|
367
|
+
# configure file_detector for remote uploads
|
368
|
+
selenium = Capybara.page.driver.browser
|
369
|
+
selenium.file_detector = lambda do |args|
|
370
|
+
str = args.first.to_s
|
371
|
+
str if File.exist?(str)
|
372
|
+
end
|
361
373
|
end
|
362
374
|
|
363
375
|
def self.initialize_gridlastic
|
@@ -388,6 +400,12 @@ module TestCentricity
|
|
388
400
|
session_id = Capybara.current_session.driver.browser.instance_variable_get(:@bridge).session_id
|
389
401
|
puts "TEST VIDEO URL: #{ENV['VIDEO_URL']}#{session_id}"
|
390
402
|
end
|
403
|
+
# configure file_detector for remote uploads
|
404
|
+
selenium = Capybara.page.driver.browser
|
405
|
+
selenium.file_detector = lambda do |args|
|
406
|
+
str = args.first.to_s
|
407
|
+
str if File.exist?(str)
|
408
|
+
end
|
391
409
|
end
|
392
410
|
|
393
411
|
def self.initialize_remote
|
@@ -419,6 +437,12 @@ module TestCentricity
|
|
419
437
|
end
|
420
438
|
Capybara.current_driver = :remote_browser
|
421
439
|
Capybara.default_driver = :remote_browser
|
440
|
+
# configure file_detector for remote uploads
|
441
|
+
selenium = Capybara.page.driver.browser
|
442
|
+
selenium.file_detector = lambda do |args|
|
443
|
+
str = args.first.to_s
|
444
|
+
str if File.exist?(str)
|
445
|
+
end
|
422
446
|
end
|
423
447
|
|
424
448
|
def self.initialize_saucelabs
|
@@ -458,6 +482,12 @@ module TestCentricity
|
|
458
482
|
|
459
483
|
Capybara.default_driver = :saucelabs
|
460
484
|
Capybara.run_server = false
|
485
|
+
# configure file_detector for remote uploads
|
486
|
+
selenium = Capybara.page.driver.browser
|
487
|
+
selenium.file_detector = lambda do |args|
|
488
|
+
str = args.first.to_s
|
489
|
+
str if File.exist?(str)
|
490
|
+
end
|
461
491
|
end
|
462
492
|
|
463
493
|
def self.initialize_testingbot
|
@@ -502,6 +532,12 @@ module TestCentricity
|
|
502
532
|
|
503
533
|
Capybara.default_driver = :testingbot
|
504
534
|
Capybara.run_server = false
|
535
|
+
# configure file_detector for remote uploads
|
536
|
+
selenium = Capybara.page.driver.browser
|
537
|
+
selenium.file_detector = lambda do |args|
|
538
|
+
str = args.first.to_s
|
539
|
+
str if File.exist?(str)
|
540
|
+
end
|
505
541
|
end
|
506
542
|
end
|
507
543
|
end
|
@@ -29,8 +29,8 @@ module TestCentricity
|
|
29
29
|
table_spec[:tree_expand] = "div/div[contains(@class, 'tree-plus treeclick')]"
|
30
30
|
table_spec[:tree_collapse] = "div/div[contains(@class, 'tree-minus treeclick')]"
|
31
31
|
when :css
|
32
|
-
table_spec[:tree_expand] = "div
|
33
|
-
table_spec[:tree_collapse] = "div
|
32
|
+
table_spec[:tree_expand] = "div > div[class*='tree-plus treeclick']"
|
33
|
+
table_spec[:tree_collapse] = "div > div[class*='tree-minus treeclick']"
|
34
34
|
end
|
35
35
|
define_table_elements(table_spec)
|
36
36
|
end
|
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.14
|
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-09-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -241,8 +241,6 @@ files:
|
|
241
241
|
- ".idea/vcs.xml"
|
242
242
|
- ".rspec"
|
243
243
|
- ".rubocop.yml"
|
244
|
-
- ".ruby-gemset"
|
245
|
-
- ".ruby-version"
|
246
244
|
- ".yardopts"
|
247
245
|
- CHANGELOG.md
|
248
246
|
- CODE_OF_CONDUCT.md
|
data/.ruby-gemset
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
testcentricity_web
|
data/.ruby-version
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
ruby-2.3.0
|