Class: TestCentricity::Environ
- Inherits:
-
DataObject
- Object
- DataObject
- TestCentricity::Environ
- Defined in:
- lib/testcentricity/data_objects/environment.rb
Instance Attribute Summary collapse
-
#a11y_standard ⇒ Object
Returns the value of attribute a11y_standard.
-
#android_apk_path ⇒ Object
Returns the value of attribute android_apk_path.
-
#android_app_id ⇒ Object
Returns the value of attribute android_app_id.
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#app_host ⇒ Object
Returns the value of attribute app_host.
-
#app_id ⇒ Object
Returns the value of attribute app_id.
-
#append ⇒ Object
Returns the value of attribute append.
-
#base_url ⇒ Object
Returns the value of attribute base_url.
-
#browser ⇒ Object
Returns the value of attribute browser.
-
#browser_size ⇒ Object
Returns the value of attribute browser_size.
-
#db_password ⇒ Object
Returns the value of attribute db_password.
-
#db_username ⇒ Object
Returns the value of attribute db_username.
-
#deep_link_prefix ⇒ Object
Returns the value of attribute deep_link_prefix.
-
#default_max_wait_time ⇒ Object
Returns the value of attribute default_max_wait_time.
-
#device ⇒ Object
Returns the value of attribute device.
-
#device_name ⇒ Object
Returns the value of attribute device_name.
-
#device_orientation ⇒ Object
Returns the value of attribute device_orientation.
-
#device_os ⇒ Object
Returns the value of attribute device_os.
-
#device_os_version ⇒ Object
Returns the value of attribute device_os_version.
-
#device_type ⇒ Object
Returns the value of attribute device_type.
-
#dns ⇒ Object
Returns the value of attribute dns.
-
#driver ⇒ Object
Returns the value of attribute driver.
-
#external_page ⇒ Object
Returns the value of attribute external_page.
-
#grid ⇒ Object
Returns the value of attribute grid.
-
#headless ⇒ Object
Returns the value of attribute headless.
-
#hostname ⇒ Object
Returns the value of attribute hostname.
-
#ios_app_path ⇒ Object
Returns the value of attribute ios_app_path.
-
#ios_bundle_id ⇒ Object
Returns the value of attribute ios_bundle_id.
-
#ios_ipa_path ⇒ Object
Returns the value of attribute ios_ipa_path.
-
#language ⇒ Object
Returns the value of attribute language.
-
#locale ⇒ Object
Returns the value of attribute locale.
-
#option1 ⇒ Object
Returns the value of attribute option1.
-
#option2 ⇒ Object
Returns the value of attribute option2.
-
#option3 ⇒ Object
Returns the value of attribute option3.
-
#option4 ⇒ Object
Returns the value of attribute option4.
-
#os ⇒ Object
Returns the value of attribute os.
-
#parallel ⇒ Object
Returns the value of attribute parallel.
-
#password ⇒ Object
Returns the value of attribute password.
-
#platform ⇒ Object
Returns the value of attribute platform.
-
#portal_context ⇒ Object
Returns the value of attribute portal_context.
-
#portal_status ⇒ Object
Returns the value of attribute portal_status.
-
#process_num ⇒ Object
Returns the value of attribute process_num.
-
#protocol ⇒ Object
Returns the value of attribute protocol.
-
#screen_size ⇒ Object
Returns the value of attribute screen_size.
-
#session_code ⇒ Object
Returns the value of attribute session_code.
-
#session_state ⇒ Object
Returns the value of attribute session_state.
-
#signed_in ⇒ Object
Returns the value of attribute signed_in.
-
#test_environment ⇒ Object
Returns the value of attribute test_environment.
-
#tunneling ⇒ Object
Returns the value of attribute tunneling.
-
#user_id ⇒ Object
Returns the value of attribute user_id.
Class Method Summary collapse
- .app_host ⇒ Object
- .browser ⇒ Object
- .browser=(browser) ⇒ Object
- .browser_size ⇒ Object
- .browser_size=(size) ⇒ Object
- .default_max_wait_time ⇒ Object
- .default_max_wait_time=(timeout) ⇒ Object
- .device ⇒ Object
- .device=(device) ⇒ Object
- .device_name ⇒ Object
- .device_name=(name) ⇒ Object
- .device_orientation ⇒ Object
- .device_orientation=(orientation) ⇒ Object
- .device_os ⇒ Object
- .device_os=(os) ⇒ Object
- .device_os_version ⇒ Object
- .device_os_version=(version) ⇒ Object
- .device_type ⇒ Object
- .device_type=(type) ⇒ Object
- .driver ⇒ Object
- .driver=(type) ⇒ Object
- .external_page ⇒ Object
- .get_screen_shots ⇒ Object
- .grid ⇒ Object
- .grid=(type) ⇒ Object
- .headless ⇒ Object
- .headless=(state) ⇒ Object
- .is_android? ⇒ Boolean
- .is_desktop? ⇒ Boolean
- .is_device? ⇒ Boolean
- .is_ios? ⇒ Boolean
- .is_mobile? ⇒ Boolean
- .is_signed_in? ⇒ Boolean
- .is_simulator? ⇒ Boolean
- .is_web? ⇒ Boolean
- .language ⇒ Object
- .language=(language) ⇒ Object
- .locale ⇒ Object
- .locale=(locale) ⇒ Object
- .os ⇒ Object
- .os=(os) ⇒ Object
- .parallel ⇒ Object
- .parallel=(state) ⇒ Object
- .platform ⇒ Object
- .platform=(platform) ⇒ Object
- .portal_context ⇒ Object
- .portal_context=(portal_context) ⇒ Object
- .portal_state ⇒ Object
- .portal_state=(portal_state) ⇒ Object
- .process_num ⇒ Object
- .process_num=(num) ⇒ Object
-
.report_header ⇒ Object
:nocov:.
- .reset_contexts ⇒ Object
- .save_screen_shot(screen_shot) ⇒ Object
- .screen_size ⇒ Object
- .screen_size=(size) ⇒ Object
- .session_code ⇒ Object
- .session_id ⇒ Object
- .session_state ⇒ Object
- .session_state=(session_state) ⇒ Object
- .session_time_stamp ⇒ Object
- .set_external_page(state) ⇒ Object
- .set_signed_in(signed_in) ⇒ Object
- .test_environment ⇒ Object
- .tunneling ⇒ Object
- .tunneling=(state) ⇒ Object
Instance Method Summary collapse
-
#initialize(data) ⇒ Environ
constructor
A new instance of Environ.
Constructor Details
#initialize(data) ⇒ Environ
Returns a new instance of Environ.
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 |
# File 'lib/testcentricity/data_objects/environment.rb', line 66 def initialize(data) @protocol = data['PROTOCOL'] @hostname = data['HOST_NAME'] @base_url = data['BASE_URL'] @user_id = data['USER_ID'] @password = data['PASSWORD'] @append = data['APPEND'] @app_id = data['APP_ID'] @api_key = data['API_KEY'] @option1 = data['OPTIONAL_1'] @option2 = data['OPTIONAL_2'] @option3 = data['OPTIONAL_3'] @option4 = data['OPTIONAL_4'] @dns = data['DNS'] @db_username = data['DB_USERNAME'] @db_password = data['DB_PASSWORD'] @ios_app_path = data['IOS_APP_PATH'] @ios_ipa_path = data['IOS_IPA_PATH'] @android_apk_path = data['ANDROID_APK_PATH'] @deep_link_prefix = data['DEEP_LINK_PREFIX'] @ios_bundle_id = data['IOS_BUNDLE_ID'] @android_app_id = data['ANDROID_APP_ID'] url = @hostname.blank? ? "#{@base_url}#{@append}" : "#{@hostname}/#{@base_url}#{@append}" @app_host = if @user_id.blank? || @password.blank? "#{@protocol}://#{url}" else "#{@protocol}://#{@user_id}:#{@password}@#{url}" end super end |
Instance Attribute Details
#a11y_standard ⇒ Object
Returns the value of attribute a11y_standard.
41 42 43 |
# File 'lib/testcentricity/data_objects/environment.rb', line 41 def a11y_standard @a11y_standard end |
#android_apk_path ⇒ Object
Returns the value of attribute android_apk_path.
60 61 62 |
# File 'lib/testcentricity/data_objects/environment.rb', line 60 def android_apk_path @android_apk_path end |
#android_app_id ⇒ Object
Returns the value of attribute android_app_id.
64 65 66 |
# File 'lib/testcentricity/data_objects/environment.rb', line 64 def android_app_id @android_app_id end |
#api_key ⇒ Object
Returns the value of attribute api_key.
50 51 52 |
# File 'lib/testcentricity/data_objects/environment.rb', line 50 def api_key @api_key end |
#app_host ⇒ Object
Returns the value of attribute app_host.
12 13 14 |
# File 'lib/testcentricity/data_objects/environment.rb', line 12 def app_host @app_host end |
#app_id ⇒ Object
Returns the value of attribute app_id.
49 50 51 |
# File 'lib/testcentricity/data_objects/environment.rb', line 49 def app_id @app_id end |
#append ⇒ Object
Returns the value of attribute append.
48 49 50 |
# File 'lib/testcentricity/data_objects/environment.rb', line 48 def append @append end |
#base_url ⇒ Object
Returns the value of attribute base_url.
45 46 47 |
# File 'lib/testcentricity/data_objects/environment.rb', line 45 def base_url @base_url end |
#browser ⇒ Object
Returns the value of attribute browser.
13 14 15 |
# File 'lib/testcentricity/data_objects/environment.rb', line 13 def browser @browser end |
#browser_size ⇒ Object
Returns the value of attribute browser_size.
14 15 16 |
# File 'lib/testcentricity/data_objects/environment.rb', line 14 def browser_size @browser_size end |
#db_password ⇒ Object
Returns the value of attribute db_password.
57 58 59 |
# File 'lib/testcentricity/data_objects/environment.rb', line 57 def db_password @db_password end |
#db_username ⇒ Object
Returns the value of attribute db_username.
56 57 58 |
# File 'lib/testcentricity/data_objects/environment.rb', line 56 def db_username @db_username end |
#deep_link_prefix ⇒ Object
Returns the value of attribute deep_link_prefix.
62 63 64 |
# File 'lib/testcentricity/data_objects/environment.rb', line 62 def deep_link_prefix @deep_link_prefix end |
#default_max_wait_time ⇒ Object
Returns the value of attribute default_max_wait_time.
61 62 63 |
# File 'lib/testcentricity/data_objects/environment.rb', line 61 def default_max_wait_time @default_max_wait_time end |
#device ⇒ Object
Returns the value of attribute device.
19 20 21 |
# File 'lib/testcentricity/data_objects/environment.rb', line 19 def device @device end |
#device_name ⇒ Object
Returns the value of attribute device_name.
20 21 22 |
# File 'lib/testcentricity/data_objects/environment.rb', line 20 def device_name @device_name end |
#device_orientation ⇒ Object
Returns the value of attribute device_orientation.
24 25 26 |
# File 'lib/testcentricity/data_objects/environment.rb', line 24 def device_orientation @device_orientation end |
#device_os ⇒ Object
Returns the value of attribute device_os.
22 23 24 |
# File 'lib/testcentricity/data_objects/environment.rb', line 22 def device_os @device_os end |
#device_os_version ⇒ Object
Returns the value of attribute device_os_version.
23 24 25 |
# File 'lib/testcentricity/data_objects/environment.rb', line 23 def device_os_version @device_os_version end |
#device_type ⇒ Object
Returns the value of attribute device_type.
21 22 23 |
# File 'lib/testcentricity/data_objects/environment.rb', line 21 def device_type @device_type end |
#dns ⇒ Object
Returns the value of attribute dns.
55 56 57 |
# File 'lib/testcentricity/data_objects/environment.rb', line 55 def dns @dns end |
#driver ⇒ Object
Returns the value of attribute driver.
27 28 29 |
# File 'lib/testcentricity/data_objects/environment.rb', line 27 def driver @driver end |
#external_page ⇒ Object
Returns the value of attribute external_page.
39 40 41 |
# File 'lib/testcentricity/data_objects/environment.rb', line 39 def external_page @external_page end |
#grid ⇒ Object
Returns the value of attribute grid.
28 29 30 |
# File 'lib/testcentricity/data_objects/environment.rb', line 28 def grid @grid end |
#headless ⇒ Object
Returns the value of attribute headless.
15 16 17 |
# File 'lib/testcentricity/data_objects/environment.rb', line 15 def headless @headless end |
#hostname ⇒ Object
Returns the value of attribute hostname.
44 45 46 |
# File 'lib/testcentricity/data_objects/environment.rb', line 44 def hostname @hostname end |
#ios_app_path ⇒ Object
Returns the value of attribute ios_app_path.
58 59 60 |
# File 'lib/testcentricity/data_objects/environment.rb', line 58 def ios_app_path @ios_app_path end |
#ios_bundle_id ⇒ Object
Returns the value of attribute ios_bundle_id.
63 64 65 |
# File 'lib/testcentricity/data_objects/environment.rb', line 63 def ios_bundle_id @ios_bundle_id end |
#ios_ipa_path ⇒ Object
Returns the value of attribute ios_ipa_path.
59 60 61 |
# File 'lib/testcentricity/data_objects/environment.rb', line 59 def ios_ipa_path @ios_ipa_path end |
#language ⇒ Object
Returns the value of attribute language.
31 32 33 |
# File 'lib/testcentricity/data_objects/environment.rb', line 31 def language @language end |
#locale ⇒ Object
Returns the value of attribute locale.
30 31 32 |
# File 'lib/testcentricity/data_objects/environment.rb', line 30 def locale @locale end |
#option1 ⇒ Object
Returns the value of attribute option1.
51 52 53 |
# File 'lib/testcentricity/data_objects/environment.rb', line 51 def option1 @option1 end |
#option2 ⇒ Object
Returns the value of attribute option2.
52 53 54 |
# File 'lib/testcentricity/data_objects/environment.rb', line 52 def option2 @option2 end |
#option3 ⇒ Object
Returns the value of attribute option3.
53 54 55 |
# File 'lib/testcentricity/data_objects/environment.rb', line 53 def option3 @option3 end |
#option4 ⇒ Object
Returns the value of attribute option4.
54 55 56 |
# File 'lib/testcentricity/data_objects/environment.rb', line 54 def option4 @option4 end |
#os ⇒ Object
Returns the value of attribute os.
18 19 20 |
# File 'lib/testcentricity/data_objects/environment.rb', line 18 def os @os end |
#parallel ⇒ Object
Returns the value of attribute parallel.
33 34 35 |
# File 'lib/testcentricity/data_objects/environment.rb', line 33 def parallel @parallel end |
#password ⇒ Object
Returns the value of attribute password.
47 48 49 |
# File 'lib/testcentricity/data_objects/environment.rb', line 47 def password @password end |
#platform ⇒ Object
Returns the value of attribute platform.
26 27 28 |
# File 'lib/testcentricity/data_objects/environment.rb', line 26 def platform @platform end |
#portal_context ⇒ Object
Returns the value of attribute portal_context.
38 39 40 |
# File 'lib/testcentricity/data_objects/environment.rb', line 38 def portal_context @portal_context end |
#portal_status ⇒ Object
Returns the value of attribute portal_status.
37 38 39 |
# File 'lib/testcentricity/data_objects/environment.rb', line 37 def portal_status @portal_status end |
#process_num ⇒ Object
Returns the value of attribute process_num.
34 35 36 |
# File 'lib/testcentricity/data_objects/environment.rb', line 34 def process_num @process_num end |
#protocol ⇒ Object
Returns the value of attribute protocol.
43 44 45 |
# File 'lib/testcentricity/data_objects/environment.rb', line 43 def protocol @protocol end |
#screen_size ⇒ Object
Returns the value of attribute screen_size.
25 26 27 |
# File 'lib/testcentricity/data_objects/environment.rb', line 25 def screen_size @screen_size end |
#session_code ⇒ Object
Returns the value of attribute session_code.
17 18 19 |
# File 'lib/testcentricity/data_objects/environment.rb', line 17 def session_code @session_code end |
#session_state ⇒ Object
Returns the value of attribute session_state.
16 17 18 |
# File 'lib/testcentricity/data_objects/environment.rb', line 16 def session_state @session_state end |
#signed_in ⇒ Object
Returns the value of attribute signed_in.
36 37 38 |
# File 'lib/testcentricity/data_objects/environment.rb', line 36 def signed_in @signed_in end |
#test_environment ⇒ Object
Returns the value of attribute test_environment.
11 12 13 |
# File 'lib/testcentricity/data_objects/environment.rb', line 11 def test_environment @test_environment end |
#tunneling ⇒ Object
Returns the value of attribute tunneling.
29 30 31 |
# File 'lib/testcentricity/data_objects/environment.rb', line 29 def tunneling @tunneling end |
#user_id ⇒ Object
Returns the value of attribute user_id.
46 47 48 |
# File 'lib/testcentricity/data_objects/environment.rb', line 46 def user_id @user_id end |
Class Method Details
.app_host ⇒ Object
99 100 101 |
# File 'lib/testcentricity/data_objects/environment.rb', line 99 def self.app_host @app_host end |
.browser ⇒ Object
157 158 159 |
# File 'lib/testcentricity/data_objects/environment.rb', line 157 def self.browser @browser end |
.browser=(browser) ⇒ Object
153 154 155 |
# File 'lib/testcentricity/data_objects/environment.rb', line 153 def self.browser=(browser) @browser = browser.downcase.to_sym end |
.browser_size ⇒ Object
165 166 167 |
# File 'lib/testcentricity/data_objects/environment.rb', line 165 def self.browser_size @browser_size end |
.browser_size=(size) ⇒ Object
161 162 163 |
# File 'lib/testcentricity/data_objects/environment.rb', line 161 def self.browser_size=(size) @browser_size = size end |
.default_max_wait_time ⇒ Object
149 150 151 |
# File 'lib/testcentricity/data_objects/environment.rb', line 149 def self.default_max_wait_time @default_max_wait_time end |
.default_max_wait_time=(timeout) ⇒ Object
143 144 145 146 147 |
# File 'lib/testcentricity/data_objects/environment.rb', line 143 def self.default_max_wait_time=(timeout) @default_max_wait_time = timeout Capybara.default_max_wait_time = timeout if driver == :webdriver end |
.device ⇒ Object
197 198 199 |
# File 'lib/testcentricity/data_objects/environment.rb', line 197 def self.device @device end |
.device=(device) ⇒ Object
193 194 195 |
# File 'lib/testcentricity/data_objects/environment.rb', line 193 def self.device=(device) @device = device end |
.device_name ⇒ Object
225 226 227 |
# File 'lib/testcentricity/data_objects/environment.rb', line 225 def self.device_name @device_name end |
.device_name=(name) ⇒ Object
221 222 223 |
# File 'lib/testcentricity/data_objects/environment.rb', line 221 def self.device_name=(name) @device_name = name end |
.device_orientation ⇒ Object
257 258 259 |
# File 'lib/testcentricity/data_objects/environment.rb', line 257 def self.device_orientation @device_orientation end |
.device_orientation=(orientation) ⇒ Object
253 254 255 |
# File 'lib/testcentricity/data_objects/environment.rb', line 253 def self.device_orientation=(orientation) @device_orientation = orientation.downcase.to_sym end |
.device_os ⇒ Object
233 234 235 |
# File 'lib/testcentricity/data_objects/environment.rb', line 233 def self.device_os @device_os end |
.device_os=(os) ⇒ Object
229 230 231 |
# File 'lib/testcentricity/data_objects/environment.rb', line 229 def self.device_os=(os) @device_os = os.downcase.to_sym end |
.device_os_version ⇒ Object
241 242 243 |
# File 'lib/testcentricity/data_objects/environment.rb', line 241 def self.device_os_version @device_os_version end |
.device_os_version=(version) ⇒ Object
237 238 239 |
# File 'lib/testcentricity/data_objects/environment.rb', line 237 def self.device_os_version=(version) @device_os_version = version end |
.device_type ⇒ Object
217 218 219 |
# File 'lib/testcentricity/data_objects/environment.rb', line 217 def self.device_type @device_type end |
.device_type=(type) ⇒ Object
213 214 215 |
# File 'lib/testcentricity/data_objects/environment.rb', line 213 def self.device_type=(type) @device_type = type.downcase.to_sym end |
.driver ⇒ Object
273 274 275 |
# File 'lib/testcentricity/data_objects/environment.rb', line 273 def self.driver @driver end |
.driver=(type) ⇒ Object
269 270 271 |
# File 'lib/testcentricity/data_objects/environment.rb', line 269 def self.driver=(type) @driver = type end |
.external_page ⇒ Object
353 354 355 |
# File 'lib/testcentricity/data_objects/environment.rb', line 353 def self.external_page @external_page end |
.get_screen_shots ⇒ Object
361 362 363 |
# File 'lib/testcentricity/data_objects/environment.rb', line 361 def self.get_screen_shots @screen_shots end |
.grid ⇒ Object
281 282 283 |
# File 'lib/testcentricity/data_objects/environment.rb', line 281 def self.grid @grid end |
.grid=(type) ⇒ Object
277 278 279 |
# File 'lib/testcentricity/data_objects/environment.rb', line 277 def self.grid=(type) @grid = type end |
.headless ⇒ Object
173 174 175 |
# File 'lib/testcentricity/data_objects/environment.rb', line 173 def self.headless @headless end |
.headless=(state) ⇒ Object
169 170 171 |
# File 'lib/testcentricity/data_objects/environment.rb', line 169 def self.headless=(state) @headless = state end |
.is_android? ⇒ Boolean
249 250 251 |
# File 'lib/testcentricity/data_objects/environment.rb', line 249 def self.is_android? @device_os == :android end |
.is_desktop? ⇒ Boolean
321 322 323 |
# File 'lib/testcentricity/data_objects/environment.rb', line 321 def self.is_desktop? @platform == :desktop end |
.is_device? ⇒ Boolean
201 202 203 |
# File 'lib/testcentricity/data_objects/environment.rb', line 201 def self.is_device? @device == :device end |
.is_ios? ⇒ Boolean
245 246 247 |
# File 'lib/testcentricity/data_objects/environment.rb', line 245 def self.is_ios? @device_os == :ios end |
.is_mobile? ⇒ Boolean
317 318 319 |
# File 'lib/testcentricity/data_objects/environment.rb', line 317 def self.is_mobile? @platform == :mobile end |
.is_signed_in? ⇒ Boolean
329 330 331 |
# File 'lib/testcentricity/data_objects/environment.rb', line 329 def self.is_signed_in? @signed_in end |
.is_simulator? ⇒ Boolean
205 206 207 |
# File 'lib/testcentricity/data_objects/environment.rb', line 205 def self.is_simulator? @device == :simulator end |
.is_web? ⇒ Boolean
209 210 211 |
# File 'lib/testcentricity/data_objects/environment.rb', line 209 def self.is_web? @device == :web end |
.language ⇒ Object
297 298 299 |
# File 'lib/testcentricity/data_objects/environment.rb', line 297 def self.language @language end |
.language=(language) ⇒ Object
293 294 295 |
# File 'lib/testcentricity/data_objects/environment.rb', line 293 def self.language=(language) @language = language end |
.locale ⇒ Object
305 306 307 |
# File 'lib/testcentricity/data_objects/environment.rb', line 305 def self.locale @locale end |
.locale=(locale) ⇒ Object
301 302 303 |
# File 'lib/testcentricity/data_objects/environment.rb', line 301 def self.locale=(locale) @locale = locale end |
.os ⇒ Object
189 190 191 |
# File 'lib/testcentricity/data_objects/environment.rb', line 189 def self.os @os end |
.os=(os) ⇒ Object
185 186 187 |
# File 'lib/testcentricity/data_objects/environment.rb', line 185 def self.os=(os) @os = os end |
.parallel ⇒ Object
123 124 125 |
# File 'lib/testcentricity/data_objects/environment.rb', line 123 def self.parallel @parallel end |
.parallel=(state) ⇒ Object
119 120 121 |
# File 'lib/testcentricity/data_objects/environment.rb', line 119 def self.parallel=(state) @parallel = state end |
.platform ⇒ Object
313 314 315 |
# File 'lib/testcentricity/data_objects/environment.rb', line 313 def self.platform @platform end |
.platform=(platform) ⇒ Object
309 310 311 |
# File 'lib/testcentricity/data_objects/environment.rb', line 309 def self.platform=(platform) @platform = platform end |
.portal_context ⇒ Object
345 346 347 |
# File 'lib/testcentricity/data_objects/environment.rb', line 345 def self.portal_context @portal_context end |
.portal_context=(portal_context) ⇒ Object
341 342 343 |
# File 'lib/testcentricity/data_objects/environment.rb', line 341 def self.portal_context=(portal_context) @portal_context = portal_context end |
.portal_state ⇒ Object
337 338 339 |
# File 'lib/testcentricity/data_objects/environment.rb', line 337 def self.portal_state @portal_status end |
.portal_state=(portal_state) ⇒ Object
333 334 335 |
# File 'lib/testcentricity/data_objects/environment.rb', line 333 def self.portal_state=(portal_state) @portal_status = portal_state end |
.process_num ⇒ Object
131 132 133 |
# File 'lib/testcentricity/data_objects/environment.rb', line 131 def self.process_num @process_num end |
.process_num=(num) ⇒ Object
127 128 129 |
# File 'lib/testcentricity/data_objects/environment.rb', line 127 def self.process_num=(num) @process_num = num end |
.report_header ⇒ Object
:nocov:
370 371 372 373 374 375 376 377 378 379 380 381 |
# File 'lib/testcentricity/data_objects/environment.rb', line 370 def self.report_header report_header = "\n<b><u>TEST ENVIRONMENT</u>:</b> #{ENV['TEST_ENVIRONMENT']}\n"\ " <b>Target:</b>\t #{Environ.browser.capitalize}\n" report_header = "#{report_header} <b>Device:</b>\t #{Environ.device_name}\n" if Environ.device_name report_header = "#{report_header} <b>Device OS:</b>\t #{Environ.device_os} #{Environ.device_os_version}\n" if Environ.device_os report_header = "#{report_header} <b>Device type:</b>\t #{Environ.device_type}\n" if Environ.device_type report_header = "#{report_header} <b>OS:</b>\t\t #{Environ.os}\n" if Environ.os report_header = "#{report_header} <b>Locale:</b>\t #{Environ.locale}\n" if Environ.locale report_header = "#{report_header} <b>Language:</b>\t #{Environ.language}\n" if Environ.language report_header = "#{report_header} <b>Country:</b>\t #{ENV['COUNTRY']}\n" if ENV['COUNTRY'] "#{report_header}\n\n" end |
.reset_contexts ⇒ Object
365 366 367 |
# File 'lib/testcentricity/data_objects/environment.rb', line 365 def self.reset_contexts @screen_shots = [] end |
.save_screen_shot(screen_shot) ⇒ Object
357 358 359 |
# File 'lib/testcentricity/data_objects/environment.rb', line 357 def self.save_screen_shot(screen_shot) @screen_shots.push(screen_shot) end |
.screen_size ⇒ Object
265 266 267 |
# File 'lib/testcentricity/data_objects/environment.rb', line 265 def self.screen_size @screen_size end |
.screen_size=(size) ⇒ Object
261 262 263 |
# File 'lib/testcentricity/data_objects/environment.rb', line 261 def self.screen_size=(size) @screen_size = size end |
.session_code ⇒ Object
103 104 105 106 107 108 109 |
# File 'lib/testcentricity/data_objects/environment.rb', line 103 def self.session_code if @session_code.nil? characters = ('a'..'z').to_a @session_code = (0..12).map { characters.sample }.join end @session_code end |
.session_id ⇒ Object
111 112 113 |
# File 'lib/testcentricity/data_objects/environment.rb', line 111 def self.session_id @session_id end |
.session_state ⇒ Object
181 182 183 |
# File 'lib/testcentricity/data_objects/environment.rb', line 181 def self.session_state @session_state end |
.session_state=(session_state) ⇒ Object
177 178 179 |
# File 'lib/testcentricity/data_objects/environment.rb', line 177 def self.session_state=(session_state) @session_state = session_state end |
.session_time_stamp ⇒ Object
115 116 117 |
# File 'lib/testcentricity/data_objects/environment.rb', line 115 def self.session_time_stamp @session_time_stamp end |
.set_external_page(state) ⇒ Object
349 350 351 |
# File 'lib/testcentricity/data_objects/environment.rb', line 349 def self.set_external_page(state) @external_page = state end |
.set_signed_in(signed_in) ⇒ Object
325 326 327 |
# File 'lib/testcentricity/data_objects/environment.rb', line 325 def self.set_signed_in(signed_in) @signed_in = signed_in end |
.test_environment ⇒ Object
135 136 137 138 139 140 141 |
# File 'lib/testcentricity/data_objects/environment.rb', line 135 def self.test_environment if @test_environment.blank? nil else @test_environment.downcase.to_sym end end |
.tunneling ⇒ Object
289 290 291 |
# File 'lib/testcentricity/data_objects/environment.rb', line 289 def self.tunneling @tunneling end |
.tunneling=(state) ⇒ Object
285 286 287 |
# File 'lib/testcentricity/data_objects/environment.rb', line 285 def self.tunneling=(state) @tunneling = state end |