testcentricity 3.0.2 → 3.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 41e56d7105e8f78fed36005c744aa16235924b070accc2e6b75dbe547a5503a4
4
- data.tar.gz: 120aa790da5129d8dbd0dd316b03cd4692f0de122b8e8cbf81db9bd44a064506
3
+ metadata.gz: 653059007c2c5f64363dd2d44956b75609a84adffa34a8e9a9d1801b65686dd3
4
+ data.tar.gz: 8913e34345d85bb0877a8a924b4acc8df39d690f320c72b25787cfa524fd7564
5
5
  SHA512:
6
- metadata.gz: a86f413b8aed68b37c37e4f1a6e68c1a702b5b314775a641ed588fae53c0903848b07ce250ff6a8cee72e4439ff243aee6f7caeb8eb6ece2135d593ef211e82f
7
- data.tar.gz: 670f14489463c563c9f3b7693b477c2981d7191af904955a2615b9790183c13bf855b72b8f6bd00f8f6b7dfd2ab41cae78b7d808be3644934849da3f44f395c6
6
+ metadata.gz: 021c2b6c8e01f0909b55d8d99797c37b92d3c77fd08665b7760b4943568064cdfebbc167c194a078cb7a0e250f606c83475ac1329d8ac9c032873cbe3f175b38
7
+ data.tar.gz: e448537732ba7b53f4dad239f9c9695031ac501bce2aff0f64eed50e459c573ae2af431ef73a1732a850a756d0a496436d26e9c3c7c766d08f14ea4933561616
data/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
  All notable changes to this project will be documented in this file.
3
3
 
4
4
 
5
+ ## [3.0.3] - 30-MAY-2022
6
+
7
+ ### Added
8
+ * Added `AppAlert.await_and_respond` method.
9
+
10
+
5
11
  ## [3.0.2] - 26-MAY-2022
6
12
 
7
13
  ### Fixed
data/config/cucumber.yml CHANGED
@@ -21,6 +21,7 @@ bvt: <%= acceptance %>
21
21
  #==============
22
22
 
23
23
  report: <%= reports %> REPORTING=true
24
+ parallel: PARALLEL=true REPORTING=true --require features --format pretty --format html --out reports/test_results<%= ENV['TEST_ENV_NUMBER'] %>.html --format junit --out reports --format json --out reports/test_results<%= ENV['TEST_ENV_NUMBER'] %>.json
24
25
 
25
26
 
26
27
  #==============
@@ -1,11 +1,15 @@
1
- Form_data:
2
- primary:
3
- username: "Ignatius von Snicklefritz"
4
- password: "T0p_Sekrit"
5
- image_filename: "Wilder.jpg"
6
- multi_select: "Selection Item 2"
7
- drop_down_item: "Drop Down Item 5"
8
- check1: true
9
- check2: true
10
- check3: false
11
- radio_select: 2
1
+
2
+ User_creds:
3
+ valid_data:
4
+ username: 'bob@example.com'
5
+ password: '10203040'
6
+ invalid_user:
7
+ username: 'iggy.snicklefritz@example.com'
8
+ password: '10203040'
9
+ locked_account:
10
+ username: 'alice@example.com'
11
+ password: '10203040'
12
+ no_username:
13
+ password: '10203040'
14
+ no_password:
15
+ username: 'bob@example.com'
@@ -7,4 +7,3 @@ Environments:
7
7
  IOS_APP_PATH: '/Users/Shared/Test_Apps/iOS/MyRNDemoApp.app'
8
8
  IOS_IPA_PATH: '/Users/Shared/Test_Apps/iOS/iOS-Real-Device-MyRNDemoApp.1.3.0-162.ipa'
9
9
  ANDROID_APK_PATH: '/Users/Shared/Test_Apps/Android/Android-MyDemoAppRN.1.2.0.build-231.apk'
10
-
@@ -29,3 +29,15 @@ Feature: Screen Navigation
29
29
  |Login |
30
30
  |Webview |
31
31
  |SauceBot Video |
32
+
33
+
34
+ Scenario Outline: Verify screen navigation features with popup modals
35
+ When I tap the <screen_name> navigation menu item
36
+ And I accept the popup request modal
37
+ Then I expect the <screen_name> screen to be correctly displayed
38
+
39
+ Examples:
40
+ |screen_name |
41
+ |QR Code Scanner |
42
+ |Geo Location |
43
+ |Biometrics |
@@ -18,6 +18,7 @@ When(/^I (?:click|tap) the ([^\"]*) navigation menu item$/) do |screen_name|
18
18
  # find and navigate to the specified target page/screen
19
19
  target_page = PageManager.find_page(screen_name)
20
20
  target_page.navigate_to
21
+ PageManager.current_page = target_page
21
22
  end
22
23
 
23
24
 
@@ -30,25 +31,9 @@ Then(/^I expect the (.*) (?:page|screen) to be correctly displayed$/) do |screen
30
31
  end
31
32
 
32
33
 
33
- When(/^I enter user credentials with (.*)$/) do |reason|
34
- case reason.gsub(/\s+/, '_').downcase.to_sym
35
- when :valid_data
36
- username = 'bob@example.com'
37
- password = '10203040'
38
- when :invalid_user
39
- username = 'iggy.snicklefritz@example.com'
40
- password = '10203040'
41
- when :locked_account
42
- username = 'alice@example.com'
43
- password = '10203040'
44
- when :no_username
45
- password = '10203040'
46
- when :no_password
47
- username = 'bob@example.com'
48
- else
49
- raise "#{reason} is not a valid selector"
50
- end
51
- login_screen.login(username, password)
34
+ When(/^I enter user credentials with (.*)$/) do |creds|
35
+ cred_data = user_data_source.find_user_creds(creds.gsub(/\s+/, '_').downcase)
36
+ login_screen.login(cred_data.username, cred_data.password)
52
37
  end
53
38
 
54
39
 
@@ -70,3 +55,8 @@ end
70
55
  Then(/^I expect the navigation menu to be hidden$/) do
71
56
  PageManager.current_page.verify_nav_menu(state = :closed)
72
57
  end
58
+
59
+
60
+ When(/^I (.*) the popup request modal$/) do |action|
61
+ PageManager.current_page.modal_action(action)
62
+ end
@@ -8,6 +8,8 @@ class BaseAppScreen < TestCentricity::ScreenObject
8
8
  cart_button: { accessibility_id: 'cart badge' }
9
9
  labels header_label: { xpath: '//android.view.ViewGroup[@content-desc="container header"]/android.widget.TextView' },
10
10
  cart_quantity: { xpath: '//android.view.ViewGroup[@content-desc="cart badge"]/android.widget.TextView' }
11
+ alerts grant_modal: { id: 'com.android.permissioncontroller:id/grant_dialog' },
12
+ alert_modal: { id: 'android:id/parentPanel' }
11
13
  section :nav_menu, NavMenu
12
14
 
13
15
  def verify_page_ui
@@ -0,0 +1,17 @@
1
+ class BiometricsScreen < BaseAppScreen
2
+ trait(:page_name) { 'Biometrics' }
3
+ trait(:page_locator) { { accessibility_id: 'biometrics screen' } }
4
+ trait(:navigator) { nav_menu.open_biometrics }
5
+
6
+ # Biometrics screen UI elements
7
+ switch :fingerprint_switch, { accessibility_id: 'biometrics switch'}
8
+
9
+ def verify_page_ui
10
+ super
11
+ ui = {
12
+ header_label => { visible: true, caption: 'FingerPrint' },
13
+ fingerprint_switch => { visible: true, enabled: false }
14
+ }
15
+ verify_ui_states(ui)
16
+ end
17
+ end
@@ -0,0 +1,28 @@
1
+ class GeoLocationScreen < BaseAppScreen
2
+ trait(:page_name) { 'Geo Location' }
3
+ trait(:page_locator) { { accessibility_id: 'geo location screen' } }
4
+ trait(:page_url) { 'geo-locations' }
5
+ trait(:navigator) { nav_menu.open_geo_location }
6
+
7
+ # Geo Location screen UI elements
8
+ buttons start_observing_button: { accessibility_id: 'Start Observing button'},
9
+ stop_observing_button: { accessibility_id: 'Stop Observing button'}
10
+ labels latitude_data: { accessibility_id: 'latitude data' },
11
+ longitude_data: { accessibility_id: 'longitude data' }
12
+
13
+ def verify_page_ui
14
+ super
15
+ ui = {
16
+ header_label => { visible: true, caption: 'Geo Location' },
17
+ start_observing_button => { visible: true, enabled: false, caption: 'Start Observing' },
18
+ stop_observing_button => { visible: true, enabled: true, caption: 'Stop Observing' },
19
+ latitude_data => { visible: true, caption: { not_equal: '0' } },
20
+ longitude_data => { visible: true, caption: { not_equal: '0' } }
21
+ }
22
+ verify_ui_states(ui)
23
+ end
24
+
25
+ def modal_action(action)
26
+ grant_modal.await_and_respond(action.downcase.to_sym, timeout = 1, button_name = 'Only this time')
27
+ end
28
+ end
@@ -0,0 +1,15 @@
1
+ class QRCodeScannerScreen < BaseAppScreen
2
+ trait(:page_name) { 'QR Code Scanner' }
3
+ trait(:page_locator) { { accessibility_id: 'qr code screen' } }
4
+ trait(:page_url) { 'qr-code-scanner' }
5
+ trait(:navigator) { nav_menu.open_qr_code_scanner }
6
+
7
+ def verify_page_ui
8
+ super
9
+ verify_ui_states(header_label => { visible: true, caption: 'QR Code Scanner' })
10
+ end
11
+
12
+ def modal_action(action)
13
+ grant_modal.await_and_respond(action.downcase.to_sym, timeout = 1, button_name = 'Only this time')
14
+ end
15
+ end
@@ -0,0 +1,17 @@
1
+ class UserDataSource < TestCentricity::DataSource
2
+ def find_user_creds(node_name)
3
+ UserData.current = UserData.new(environs.read('User_creds', node_name))
4
+ end
5
+ end
6
+
7
+
8
+ class UserData < TestCentricity::DataPresenter
9
+ attribute :username, String
10
+ attribute :password, String
11
+
12
+ def initialize(data)
13
+ @username = data[:username]
14
+ @password = data[:password]
15
+ super
16
+ end
17
+ end
@@ -4,8 +4,8 @@ require 'capybara/cucumber'
4
4
  require 'parallel_tests'
5
5
  require 'require_all'
6
6
  require 'simplecov'
7
- require 'testcentricity'
8
7
  require 'testcentricity_web'
8
+ require 'testcentricity'
9
9
 
10
10
  include TestCentricity
11
11
 
@@ -14,6 +14,7 @@ SimpleCov.command_name("Features-#{ENV['PLATFORM']}-#{Time.now.strftime('%Y%m%d%
14
14
  require_relative 'world_data'
15
15
  require_relative 'world_pages'
16
16
 
17
+ require_rel 'data'
17
18
  require_rel 'shared_components'
18
19
 
19
20
  # conditionally require page and section objects based on target platform
@@ -5,6 +5,7 @@ class BaseAppScreen < TestCentricity::ScreenObject
5
5
 
6
6
  # Base App screen UI elements
7
7
  label :header_label, { accessibility_id: 'container header' }
8
+ alert :alert_modal, { class: 'XCUIElementTypeAlert' }
8
9
  sections nav_bar: NavBar,
9
10
  nav_menu: NavMenu
10
11
 
@@ -0,0 +1,17 @@
1
+ class BiometricsScreen < BaseAppScreen
2
+ trait(:page_name) { 'Biometrics' }
3
+ trait(:page_locator) { { accessibility_id: 'biometrics screen' } }
4
+ trait(:navigator) { nav_menu.open_biometrics }
5
+
6
+ # Biometrics screen UI elements
7
+ switch :face_id_switch, { accessibility_id: 'biometrics switch'}
8
+
9
+ def verify_page_ui
10
+ super
11
+ ui = {
12
+ header_label => { visible: true, caption: 'FaceID' },
13
+ face_id_switch => { visible: true, enabled: false, value: '0' }
14
+ }
15
+ verify_ui_states(ui)
16
+ end
17
+ end
@@ -0,0 +1,32 @@
1
+ class GeoLocationScreen < BaseAppScreen
2
+ trait(:page_name) { 'Geo Location' }
3
+ trait(:page_locator) { { accessibility_id: 'geo location screen' } }
4
+ trait(:page_url) { 'geo-locations' }
5
+ trait(:navigator) { nav_menu.open_geo_location }
6
+
7
+ # Geo Location screen UI elements
8
+ buttons start_observing_button: { accessibility_id: 'Start Observing button'},
9
+ stop_observing_button: { accessibility_id: 'Stop Observing button'}
10
+ labels latitude_label: { accessibility_id: 'Latitude:' },
11
+ latitude_data: { accessibility_id: 'latitude data' },
12
+ longitude_label: { accessibility_id: 'Longitude:' },
13
+ longitude_data: { accessibility_id: 'longitude data' }
14
+
15
+ def verify_page_ui
16
+ super
17
+ ui = {
18
+ header_label => { visible: true, caption: 'Geo Location' },
19
+ start_observing_button => { visible: true, enabled: false, caption: 'Start Observing' },
20
+ stop_observing_button => { visible: true, enabled: true, caption: 'Stop Observing' },
21
+ latitude_label => { visible: true, caption: 'Latitude:' },
22
+ latitude_data => { visible: true, caption: { not_equal: '0' } },
23
+ longitude_label => { visible: true, caption: 'Longitude:' },
24
+ longitude_data => { visible: true, caption: { not_equal: '0' } }
25
+ }
26
+ verify_ui_states(ui)
27
+ end
28
+
29
+ def modal_action(action)
30
+ alert_modal.await_and_respond(action.downcase.to_sym, timeout = 1, button_name = 'Allow Once')
31
+ end
32
+ end
@@ -0,0 +1,11 @@
1
+ class QRCodeScannerScreen < BaseAppScreen
2
+ trait(:page_name) { 'QR Code Scanner' }
3
+ trait(:page_locator) { { accessibility_id: 'qr code screen' } }
4
+ trait(:page_url) { 'qr-code-scanner' }
5
+ trait(:navigator) { nav_menu.open_qr_code_scanner }
6
+
7
+ def verify_page_ui
8
+ super
9
+ verify_ui_states(header_label => { visible: true, caption: 'QR Code Scanner' })
10
+ end
11
+ end
@@ -28,4 +28,8 @@ module SharedBaseAppScreen
28
28
  raise "#{action} is not a valid selector"
29
29
  end
30
30
  end
31
+
32
+ def modal_action(action)
33
+ alert_modal.await_and_respond(action.downcase.to_sym, timeout = 1)
34
+ end
31
35
  end
@@ -4,7 +4,7 @@ module WorldData
4
4
  # by the TestCentricity™ DataManager. Data Object class definitions are contained in the features/support/data folder.
5
5
  #
6
6
  def data_objects
7
- {}
7
+ { user_data_source: UserDataSource }
8
8
  end
9
9
  end
10
10
 
@@ -17,6 +17,9 @@ module WorldPages
17
17
  products_screen: ProductsScreen,
18
18
  checkout_address_screen: CheckoutAddressScreen,
19
19
  checkout_payment_screen: CheckoutPaymentScreen,
20
+ qr_code_scanner_screen: QRCodeScannerScreen,
21
+ geo_location_screen: GeoLocationScreen,
22
+ biometrics_screen: BiometricsScreen,
20
23
  saucebot_video_screen: SauceBotScreen
21
24
  }
22
25
  end
@@ -5,6 +5,16 @@ module TestCentricity
5
5
  @type = :alert
6
6
  end
7
7
 
8
+ # Wait until the alert modal is visible, or until the specified wait time has expired. If the wait time is nil, then the
9
+ # wait time will be Environ.default_max_wait_time. Unlike wait_until_visible or wait_until_exists, this method does not
10
+ # raise an exception if the alert modal does not appear within the specified wait time.
11
+ # Returns true if the alert modal is visible.
12
+ #
13
+ # @return [Integer]
14
+ # @param seconds [Integer or Float] wait time in seconds
15
+ # @example
16
+ # permissions_modal.await(2)
17
+ #
8
18
  def await(seconds)
9
19
  timeout = seconds.nil? ? Environ.default_max_wait_time : seconds
10
20
  wait = Selenium::WebDriver::Wait.new(timeout: timeout)
@@ -14,14 +24,68 @@ module TestCentricity
14
24
  false
15
25
  end
16
26
 
27
+ # Performs the action required accept the currently visible alert modal. If the alert modal is still visible after
28
+ # 5 seconds, an exception is raised.
29
+ #
30
+ # @example
31
+ # alert_modal.accept
32
+ #
17
33
  def accept
18
34
  alert_accept
19
35
  wait_until_gone(5)
20
36
  end
21
37
 
38
+ # Performs the action required dismiss the currently visible alert modal. If the alert modal is still visible after
39
+ # 5 seconds, an exception is raised.
40
+ #
41
+ # @example
42
+ # alert_modal.dismiss
43
+ #
22
44
  def dismiss
23
45
  alert_dismiss
24
46
  wait_until_gone(5)
25
47
  end
48
+
49
+ #
50
+ # @return [Integer]
51
+ # @param action [Symbol] action to perform if alert modal is visible. Acceptable values are :allow, :accept, :dont_allow, or :dismiss
52
+ # @param timeout [Integer or Float] wait time in seconds. Defaults to 2 if not specified
53
+ # @param button_name [String] optional caption of button to tap associated with the specified action
54
+ # @example
55
+ # alert_modal.await_and_respond(:dismiss)
56
+ # OR
57
+ # permissions_modal.await_and_respond(:accept, timeout = 1, button_name = 'Allow Once')
58
+ #
59
+ def await_and_respond(action, timeout = 2, button_name = nil)
60
+ if await(timeout)
61
+ case action
62
+ when :allow, :accept
63
+ if button_name.nil?
64
+ accept
65
+ elsif Environ.is_ios?
66
+ $driver.execute_script('mobile: alert', { action: 'accept', buttonLabel: button_name })
67
+ else
68
+ $driver.execute_script('mobile: acceptAlert', { buttonLabel: button_name })
69
+ end
70
+ when :dont_allow, :dismiss
71
+ if button_name.nil?
72
+ dismiss
73
+ elsif Environ.is_ios?
74
+ $driver.execute_script('mobile: alert', { action: 'dismiss', buttonLabel: button_name })
75
+ else
76
+ $driver.execute_script('mobile: dismissAlert', { buttonLabel: button_name })
77
+ end
78
+ else
79
+ raise "#{action} is not a valid selector"
80
+ end
81
+ if Environ.is_ios? && await(1)
82
+ buttons = $driver.execute_script('mobile: alert', { action: 'getButtons' })
83
+ raise "Could not perform #{action} action on active modal. Available modal buttons are #{buttons}"
84
+ end
85
+ true
86
+ else
87
+ false
88
+ end
89
+ end
26
90
  end
27
91
  end
@@ -1,3 +1,3 @@
1
1
  module TestCentricity
2
- VERSION = '3.0.2'
2
+ VERSION = '3.0.3'
3
3
  end
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
10
10
  spec.required_ruby_version = '>= 2.7.5'
11
11
  spec.authors = ['A.J. Mrozinski']
12
12
  spec.email = ['testcentricity@gmail.com']
13
- spec.summary = %q{A Page Object Model Framework for desktop/mobile web and native mobile app testing}
13
+ spec.summary = %q{A Page Object Model Framework for native mobile app and desktop/mobile web portal testing}
14
14
  spec.description = '
15
15
  The TestCentricity™ core framework for native mobile iOS and Android apps and desktop/mobile web testing implements a Page Object
16
16
  Model DSL for use with Cucumber, Appium, Capybara, and Selenium-Webdriver v4.x. The gem also facilitates the configuration of the
@@ -33,8 +33,6 @@ Gem::Specification.new do |spec|
33
33
  spec.add_development_dependency 'bundler'
34
34
  spec.add_development_dependency 'cucumber'
35
35
  spec.add_development_dependency 'cuke_modeler', '~> 3.0'
36
- spec.add_development_dependency 'curb'
37
- spec.add_development_dependency 'json'
38
36
  spec.add_development_dependency 'parallel_tests'
39
37
  spec.add_development_dependency 'rake'
40
38
  spec.add_development_dependency 'require_all', '=1.5.0'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: testcentricity
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.2
4
+ version: 3.0.3
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: 2022-05-26 00:00:00.000000000 Z
11
+ date: 2022-05-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -52,34 +52,6 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '3.0'
55
- - !ruby/object:Gem::Dependency
56
- name: curb
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - ">="
60
- - !ruby/object:Gem::Version
61
- version: '0'
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - ">="
67
- - !ruby/object:Gem::Version
68
- version: '0'
69
- - !ruby/object:Gem::Dependency
70
- name: json
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - ">="
74
- - !ruby/object:Gem::Version
75
- version: '0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: '0'
83
55
  - !ruby/object:Gem::Dependency
84
56
  name: parallel_tests
85
57
  requirement: !ruby/object:Gem::Requirement
@@ -269,27 +241,31 @@ files:
269
241
  - features/step_definitions/generic_steps.rb
270
242
  - features/support/android/screens/about_screen.rb
271
243
  - features/support/android/screens/base_app_screen.rb
244
+ - features/support/android/screens/biometrics_screen.rb
272
245
  - features/support/android/screens/checkout_address_screen.rb
273
246
  - features/support/android/screens/checkout_payment_screen.rb
247
+ - features/support/android/screens/geo_location_screen.rb
274
248
  - features/support/android/screens/login_screen.rb
275
249
  - features/support/android/screens/products_screen.rb
250
+ - features/support/android/screens/qr_code_scanner_screen.rb
276
251
  - features/support/android/screens/saucebot_screen.rb
277
252
  - features/support/android/screens/webview_screen.rb
278
253
  - features/support/android/sections/nav_widgets/nav_menu.rb
254
+ - features/support/data/user_data.rb
279
255
  - features/support/env.rb
280
256
  - features/support/hooks.rb
281
257
  - features/support/ios/screens/about_screen.rb
282
258
  - features/support/ios/screens/base_app_screen.rb
259
+ - features/support/ios/screens/biometrics_screen.rb
283
260
  - features/support/ios/screens/checkout_address_screen.rb
284
261
  - features/support/ios/screens/checkout_payment_screen.rb
262
+ - features/support/ios/screens/geo_location_screen.rb
285
263
  - features/support/ios/screens/login_screen.rb
286
264
  - features/support/ios/screens/products_screen.rb
265
+ - features/support/ios/screens/qr_code_scanner_screen.rb
287
266
  - features/support/ios/screens/saucebot_screen.rb
288
267
  - features/support/ios/screens/webview_screen.rb
289
268
  - features/support/ios/sections/list_items/product_cell_item.rb
290
- - features/support/ios/sections/modals/base_modal.rb
291
- - features/support/ios/sections/modals/logout_modal.rb
292
- - features/support/ios/sections/modals/reset_app_state_modal.rb
293
269
  - features/support/ios/sections/nav_widgets/nav_bar.rb
294
270
  - features/support/ios/sections/nav_widgets/nav_menu.rb
295
271
  - features/support/shared_components/screens/base_app_screen.rb
@@ -365,8 +341,8 @@ requirements:
365
341
  rubygems_version: 3.1.6
366
342
  signing_key:
367
343
  specification_version: 4
368
- summary: A Page Object Model Framework for desktop/mobile web and native mobile app
369
- testing
344
+ summary: A Page Object Model Framework for native mobile app and desktop/mobile web
345
+ portal testing
370
346
  test_files:
371
347
  - features/deep_links.feature
372
348
  - features/login.feature
@@ -374,27 +350,31 @@ test_files:
374
350
  - features/step_definitions/generic_steps.rb
375
351
  - features/support/android/screens/about_screen.rb
376
352
  - features/support/android/screens/base_app_screen.rb
353
+ - features/support/android/screens/biometrics_screen.rb
377
354
  - features/support/android/screens/checkout_address_screen.rb
378
355
  - features/support/android/screens/checkout_payment_screen.rb
356
+ - features/support/android/screens/geo_location_screen.rb
379
357
  - features/support/android/screens/login_screen.rb
380
358
  - features/support/android/screens/products_screen.rb
359
+ - features/support/android/screens/qr_code_scanner_screen.rb
381
360
  - features/support/android/screens/saucebot_screen.rb
382
361
  - features/support/android/screens/webview_screen.rb
383
362
  - features/support/android/sections/nav_widgets/nav_menu.rb
363
+ - features/support/data/user_data.rb
384
364
  - features/support/env.rb
385
365
  - features/support/hooks.rb
386
366
  - features/support/ios/screens/about_screen.rb
387
367
  - features/support/ios/screens/base_app_screen.rb
368
+ - features/support/ios/screens/biometrics_screen.rb
388
369
  - features/support/ios/screens/checkout_address_screen.rb
389
370
  - features/support/ios/screens/checkout_payment_screen.rb
371
+ - features/support/ios/screens/geo_location_screen.rb
390
372
  - features/support/ios/screens/login_screen.rb
391
373
  - features/support/ios/screens/products_screen.rb
374
+ - features/support/ios/screens/qr_code_scanner_screen.rb
392
375
  - features/support/ios/screens/saucebot_screen.rb
393
376
  - features/support/ios/screens/webview_screen.rb
394
377
  - features/support/ios/sections/list_items/product_cell_item.rb
395
- - features/support/ios/sections/modals/base_modal.rb
396
- - features/support/ios/sections/modals/logout_modal.rb
397
- - features/support/ios/sections/modals/reset_app_state_modal.rb
398
378
  - features/support/ios/sections/nav_widgets/nav_bar.rb
399
379
  - features/support/ios/sections/nav_widgets/nav_menu.rb
400
380
  - features/support/shared_components/screens/base_app_screen.rb
@@ -1,23 +0,0 @@
1
- class BaseIOSModal < TestCentricity::ScreenSection
2
- trait(:section_name) { 'Base iOS Modal' }
3
- trait(:section_locator) { { class: 'XCUIElementTypeAlert' } }
4
-
5
- # Base Modal UI elements
6
- alert :alert_modal, { class: 'XCUIElementTypeAlert' }
7
-
8
- def await_and_respond(action, timeout)
9
- if alert_modal.await(timeout)
10
- case action
11
- when :allow, :accept
12
- alert_modal.accept
13
- when :dont_allow, :dismiss
14
- alert_modal.dismiss
15
- else
16
- raise "#{action} is not a valid selector"
17
- end
18
- true
19
- else
20
- false
21
- end
22
- end
23
- end
@@ -1,6 +0,0 @@
1
- class LogOutModal < BaseIOSModal
2
- trait(:section_name) { 'Log Out Modal' }
3
-
4
- # Log Out Modal UI elements
5
- alert :alert_modal, { xpath: "//XCUIElementTypeAlert[@name='Log Out']" }
6
- end
@@ -1,6 +0,0 @@
1
- class ResetAppStateModal < BaseIOSModal
2
- trait(:section_name) { 'Reset App State Modal' }
3
-
4
- # Reset App State Modal UI elements
5
- alert :alert_modal, { xpath: "//XCUIElementTypeAlert[@name='Reset App State']" }
6
- end