ole-qa-framework 3.9.5 → 3.9.6

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a97922c0b475bd720f20e7ffae0b9cc694b3edc9
4
- data.tar.gz: 3bdcc60cdad4462ac7f673931fd597fded581444
3
+ metadata.gz: 4bab9684c1fc014cba91209348853f93fd21aac9
4
+ data.tar.gz: 57e8f642e6ca1dffae25a94b6ead47b2bb3e14ac
5
5
  SHA512:
6
- metadata.gz: c3b5814680ac80199b61444b99afde1fef0f89de73847b84c92eb23b2c93be774de4e7f467a65db1718f733d375004dfe9cfac6a93af5143f16fb5546858922f
7
- data.tar.gz: ced1b2a200da155007e7a16abcf76bf8b7d9a1759006858320100ede1dc2f67be0b3b123d580612387d677fc2ca2af5517e69627edee12133bfbe25bd4b55718
6
+ metadata.gz: 9820702faa9807a2f4e401f283d8c8e0b95f26df008d800ca72776bc623d2e59ee65e55c36d4bf541fee50e8944c070d9f94495301cd0cc75e392212ba6d004e
7
+ data.tar.gz: 289ccd92b67c691bd43f3a567ff586e4e45f8e2912e680ad84cdcf5777d82204d0175154d86157d1ddf4ec40093f71a7a3d0058906608fa2faefec50e3933dd5
data/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ### v3.9.6 - 2014/02/10
2
+
3
+ * Search Results Update
4
+ * For consistency, made all lookup pages with either .text_in_results or .text_in_results?
5
+ support both methods. The first returns an element, the second returns true or false based
6
+ on the presence of the element.
7
+
8
+
1
9
  ### v3.9.5 - 2014/02/06
2
10
 
3
11
  * Batch Profile (base class for Batch Export Profile & Batch Import Profile)
@@ -30,9 +30,12 @@ module OLE_QA::Framework::DocStore
30
30
  # Return an 'instance' link by a given (1-based) numerical value.
31
31
  function(:instance_link) { |which = 1| which -= 1 ; b.b(:text => /Instance/, :index => which).parent}
32
32
  # Return a field value (other than title) in the results.
33
- # @note This just returns the object for the value. Interrogate that object with .present? to confirm
34
- # its existence in the search results.
35
33
  function(:value_in_results) { |which| b.dd(:text => /#{which}/) }
34
+ # Check whether a given field value exists in the search results.
35
+ function(:value_in_results?) { |which| value_in_results(which).present?}
36
+ # Alias value_in_results and value_in_results? to text_in_results/?.
37
+ function(:text_in_results) { |which| value_in_results(which)}
38
+ function(:text_in_results?) { |which| value_in_results?(which)}
36
39
  # Return an instance link containing the given text.
37
40
  function(:instance_text) { |which| b.b(:text => /#{which}/).parent }
38
41
  end
@@ -15,6 +15,6 @@
15
15
  module OLE_QA
16
16
  module Framework
17
17
  # The version number for this project.
18
- VERSION = '3.9.5'
18
+ VERSION = '3.9.6'
19
19
  end
20
20
  end
@@ -37,6 +37,10 @@ module OLE_QA::Framework::OLEFS
37
37
  super
38
38
  # The 'return selection' link for a given text value in the search results.
39
39
  function(:return_result) {|which| b.td(:text => which).parent.td(:index => 0).a}
40
+ # Return the TD containing the given text, if it exists in the search results.
41
+ function(:text_in_results) {|which| b.td(:text => which)}
42
+ # Return true or false depending on whether the given text exists in the search results.
43
+ function(:text_in_results?) {|which| text_in_results(which).present?}
40
44
  end
41
45
  end
42
46
  end
@@ -37,6 +37,8 @@ module OLE_QA::Framework::OLEFS
37
37
  super
38
38
  # Return the link to a document by any text in the row.
39
39
  function(:doc_link_by_text) {|which| b.td(:xpath => "//table[@id='row']/descendant::td[contains(text(),'#{which}')]").parent.td(:index => 0).a}
40
+ # Return the TD element containing the given text, if it exists in the search results.
41
+ function(:text_in_results) {|which| b.td(:xpath => "//table[@id='row']/descendant::td[contains(text(),'#{which}')]")}
40
42
  # Check whether the given text exists in the search results.
41
43
  function(:text_in_results?) {|which| b.td(:xpath => "//table[@id='row']/descendant::td[contains(text(),'#{which}')]").present?}
42
44
  end
@@ -39,6 +39,10 @@ module OLE_QA::Framework::OLEFS
39
39
 
40
40
  def set_functions
41
41
  super
42
+ # Return the TD element containing the given text, if it exists in the search results.
43
+ function(:text_in_results) {|which| b.td(:index => 1).a(:text => which)}
44
+ # Return true or false based on whether the given text exists in the search results.
45
+ function(:text_in_results?) {|which| text_in_results(which).present?}
42
46
  # Get the 'return result' link for the given text in the search results.
43
47
  function(:return_result) {|which| b.td(:index => 1).a(:text => which).parent.parent.td(:index => 0).a}
44
48
  end
@@ -37,8 +37,10 @@ module OLE_QA::Framework::OLELS
37
37
 
38
38
  def set_functions
39
39
  super
40
- # Check whether the given text exists within the job details results displayed.
40
+ # If the given text appears in any of the result TDs, return that element.
41
41
  function(:text_in_results) {|text| b.td(:xpath => "//table/tbody/tr/td[div/span[contains(text(),'#{text}')]]")}
42
+ # Return true or false depending on whether or not the text is found in the search results.
43
+ function(:text_in_results?) {|text| text_in_results(text).present?}
42
44
  # Return the 'Remove' button for a row containing the given text.
43
45
  # @note This could be dangerous with the wrong selection text. Use this function carefully!
44
46
  function(:remove_by_text) {|text| b.button(:xpath=>"//table/tbody/tr[td/div/span[contains(text(),'#{text}')]]/td/div/fieldset/div/div/button[contains(text(),'Remove')]")}
@@ -42,8 +42,10 @@ module OLE_QA::Framework::OLELS
42
42
 
43
43
  def set_functions
44
44
  super
45
- # Check whether the given text exists within the search results displayed.
45
+ # If the given text exists in a TD element in the search results, return that element.
46
46
  function(:text_in_results) {|text| b.td(:xpath => "//table/tbody/tr/td[div/span[contains(text(),'#{text}')]]")}
47
+ # Return true or false based on whether the given text exists in the search results.
48
+ function(:text_in_results?) {|text| text_in_results(text).present?}
47
49
  # Return the 'Edit' link for a row containing the given text.
48
50
  function(:edit_by_text) {|text| b.a(:xpath => "//table/tbody/tr[td/div/span[contains(text(),'#{text}')]]/td[1]/div/fieldset/div/div/a[contains(text(),'edit')]")}
49
51
  # Return the Batch Process Profile ID link for a row containing the given text.
@@ -43,8 +43,10 @@ module OLE_QA::Framework::OLELS
43
43
 
44
44
  def set_functions
45
45
  super
46
- # Check whether the given text exists in the search results.
46
+ # If the given text exists in a TD element in the search results, return that element.
47
47
  function(:text_in_results) {|text| b.td(:xpath => "//table/tbody/tr/td[div/span[contains(text(),'#{text}')]]")}
48
+ # Return true or false based on whether the given text is found in the search results.
49
+ function(:text_in_results?) {|text| text_in_results(text).present?}
48
50
  # Return the Batch Process Type ID link for a row containing the given text.
49
51
  function(:id_by_text) {|text| b.a(:xpath => "//table/tbody/tr[td/div/span[contains(text(),'#{text}')]]/td/div[starts-with(@id,'result-batchProcessTypeId')]/span/a")}
50
52
  # Return the 'return value' link for a row containing the given text.
@@ -63,6 +63,10 @@ module OLE_QA::Framework::OLELS
63
63
  # Check whether the given text exists within the search results table.
64
64
  # - Returns true or false based on whether the given string was found.
65
65
  function(:result_present?) {|str| b.td(:xpath => "//table/tbody/tr/td[div/*[contains(text(),\"#{str}\")]]").present?}
66
+ # Return the TD element containing the given text, if it exists.
67
+ function(:text_in_results) {|text| b.td(:xpath => "//table/tbody/tr/td[div/*[contains(text(),\"#{text}\")]]")}
68
+ # Return true or false based on whether the given text exists in the search results.
69
+ function(:text_in_results?) {|text| text_in_results(text).present?}
66
70
  # Return the checkbox for the results line containing the given text.
67
71
  # Usage:
68
72
  # workbench.select_by_text("Foo").set(true|false)
@@ -34,8 +34,10 @@ module OLE_QA::Framework::OLELS
34
34
 
35
35
  def set_functions
36
36
  super
37
+ # Return the span element containing the given text, if it exists in the search results.
38
+ function(:text_in_results) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]")}
37
39
  # Query whether the given text value exists in the search results.
38
- function(:text_in_results?) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]")}
40
+ function(:text_in_results?) {|which| text_in_results(which).present?}
39
41
  # Return the 'edit' link for a search results line containing a given value.
40
42
  function(:edit_by_text) {|which| b.a(:xpath => "//tr[td/div/span[contains(text(),'#{which}')]]/td[1]/div/fieldset/div/div/a[contains(text(),'edit')]")}
41
43
  # Return the 'Level ID' link for a search results line containing a given value.
@@ -36,6 +36,8 @@ module OLE_QA::Framework::OLELS
36
36
 
37
37
  def set_functions
38
38
  super
39
+ # Return the span element containing the given text, if it is found in the search results.
40
+ function(:text_in_results) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]")}
39
41
  # A function to query whether a given text value exists in the search results.
40
42
  function(:text_in_results?) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]").present?}
41
43
  # Return the 'edit' link for a search results line containing the given text.
@@ -43,6 +43,8 @@ module OLE_QA::Framework::OLELS
43
43
 
44
44
  def set_functions
45
45
  super
46
+ # Return the span containing the given text, if it appears in the search results.
47
+ function(:text_in_results) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]")}
46
48
  # Return whether the given text exists in the search results.
47
49
  function(:text_in_results?) {|which| b.span(:xpath => "//td/div/span[contains(text(),'#{which}')]").present? }
48
50
  # Function used for edit_by_text, copy_by_text, and delete_by_text.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ole-qa-framework
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.9.5
4
+ version: 3.9.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jain Waldrip
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-06 00:00:00.000000000 Z
11
+ date: 2014-02-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler