itms_automation 1.3 → 1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/itms_automation/version.rb +1 -1
- data/lib/itms_automation/web_steps_helper.rb +4 -2
- data/project/features/TestSuite/WebGUI.feature +2 -1
- data/project/features/step_definitions/lib_steps/steps_definition.rb +10 -0
- data/project/features/step_definitions/repositories/project_object.yml +16 -2
- data/project/features/support/env.rb +3 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 05bc918b330ea3205841b377fa90427de896f86ac4d2921665c6742f04a968fa
|
4
|
+
data.tar.gz: 9b5af3d5827abca21f3ee2f7d1d692fa116032bd1d0c4cc4480b165e4f8ad150
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc98bf5a616b58f3231cd55c6552ee7be8cbf9c92d8ada8d9fbf129a28b768922d5183a09bebbc9fdfe543d98af881ee921f82ecc0186f403c0e7c2cb184e9f9
|
7
|
+
data.tar.gz: 7a866b84f0dc31945b0b28fa41a38d1cb31072f60e58582f5dd44c21226ff8d1ac5f6f302775e9dd9cafaeff9a34f56348ec6dc804ef142d44a8cc5fc77b0ff3
|
@@ -242,13 +242,14 @@ def resize_window_screen(x, y)
|
|
242
242
|
end
|
243
243
|
|
244
244
|
def switch_to_iframe(element)
|
245
|
-
foundElement = find_object(element)
|
246
245
|
begin
|
247
|
-
|
246
|
+
foundElement = find_object(element)
|
247
|
+
page.driver.switch_to_frame(foundElement)
|
248
248
|
rescue Exception => e
|
249
249
|
raise "❌ Error: #{e}"
|
250
250
|
end
|
251
251
|
end
|
252
|
+
|
252
253
|
def switch_out_frame
|
253
254
|
begin
|
254
255
|
browser = page.driver.browser
|
@@ -257,6 +258,7 @@ def switch_out_frame
|
|
257
258
|
raise "❌ Error: #{e}"
|
258
259
|
end
|
259
260
|
end
|
261
|
+
|
260
262
|
def get_computed_style(element, style)
|
261
263
|
foundElement = get_object_value(element)
|
262
264
|
computedStyle = ""
|
@@ -1,3 +1,13 @@
|
|
1
1
|
And /I open the page "(.*)"/ do |url_site|
|
2
2
|
execute_openbrowser(url_site)
|
3
3
|
end
|
4
|
+
|
5
|
+
Given /^test select execute$/ do
|
6
|
+
execute_openbrowser("http://www.yopmail.com/en/")
|
7
|
+
execute_settext("username", "cuong")
|
8
|
+
execute_click("okbutton")
|
9
|
+
switch_to_iframe("iframe")
|
10
|
+
|
11
|
+
execute_click("verify")
|
12
|
+
sleep(5)
|
13
|
+
end
|
@@ -1,2 +1,16 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
username: { xpath_selector: '//input[@id="login"]' }
|
2
|
+
okbutton: { xpath_selector: '//input[@value="Check Inbox"]' }
|
3
|
+
iframe: { xpath_selector: '//iframe[@id="ifmail"]' }
|
4
|
+
verify: { xpath_selector: '//div[@id="mailmillieu"]/div[2]//tbody/tr[3]/td/p/strong/a[@class="campaign-sale-link"]' }
|
5
|
+
firstname:
|
6
|
+
{
|
7
|
+
xpath_selector: '/html/body/div[2]/table/tbody/tr/td[2]/table/tbody/tr[4]/td/table/tbody/tr/td[2]/table/tbody/tr[5]/td/form/table/tbody/tr[2]/td[2]',
|
8
|
+
}
|
9
|
+
lastname:
|
10
|
+
{
|
11
|
+
xpath_selector: '/html/body/div[2]/table/tbody/tr/td[2]/table/tbody/tr[4]/td/table/tbody/tr/td[2]/table/tbody/tr[5]/td/form/table/tbody/tr[3]/td[2]/input',
|
12
|
+
}
|
13
|
+
selectcountry:
|
14
|
+
{
|
15
|
+
xpath_selector: '/html/body/div[2]/table/tbody/tr/td[2]/table/tbody/tr[4]/td/table/tbody/tr/td[2]/table/tbody/tr[5]/td/form/table/tbody/tr[11]/td[2]/select',
|
16
|
+
}
|
@@ -5,6 +5,8 @@ require 'capybara/cucumber'
|
|
5
5
|
require 'cucumber'
|
6
6
|
require 'yaml'
|
7
7
|
require 'selenium-webdriver'
|
8
|
-
require 'itms_automation'
|
8
|
+
# require 'itms_automation'
|
9
9
|
require 'report_builder'
|
10
10
|
|
11
|
+
require_relative "../../../lib/itms_automation.rb"
|
12
|
+
# Selenium::WebDriver::Driver.for(:remote).logger.level = :debug
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: itms_automation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '1.
|
4
|
+
version: '1.4'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anh Pham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-02-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: selenium-webdriver
|